mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-16 17:46:45 +00:00
ci: Sanitize package name before using it for build artifact (#19711)
This commit is contained in:
18
.github/workflows/release-standalone-package.yml
vendored
18
.github/workflows/release-standalone-package.yml
vendored
@@ -12,9 +12,6 @@ on:
|
|||||||
- '@n8n/create-node'
|
- '@n8n/create-node'
|
||||||
- '@n8n/scan-community-package'
|
- '@n8n/scan-community-package'
|
||||||
|
|
||||||
env:
|
|
||||||
BUILD_DIST_NAME: ${{ github.sha }}-${{ github.event.inputs.package }}-build
|
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: release-package-${{ github.event.inputs.package }}
|
group: release-package-${{ github.event.inputs.package }}
|
||||||
cancel-in-progress: false
|
cancel-in-progress: false
|
||||||
@@ -36,8 +33,19 @@ jobs:
|
|||||||
needs: validate
|
needs: validate
|
||||||
runs-on: blacksmith-4vcpu-ubuntu-2204
|
runs-on: blacksmith-4vcpu-ubuntu-2204
|
||||||
timeout-minutes: 15
|
timeout-minutes: 15
|
||||||
|
outputs:
|
||||||
|
artifact-name: ${{ steps.sanitize.outputs.result }}
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
|
- name: Create sanitized artifact name
|
||||||
|
id: sanitize
|
||||||
|
uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8.0.0
|
||||||
|
with:
|
||||||
|
script: |
|
||||||
|
const packageName = '${{ github.event.inputs.package }}';
|
||||||
|
const sanitizedName = packageName.replace(/[/:]/g, '-');
|
||||||
|
return `${{ github.sha }}-${sanitizedName}-build`;
|
||||||
|
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
||||||
with:
|
with:
|
||||||
@@ -51,7 +59,7 @@ jobs:
|
|||||||
- name: Upload build artifacts
|
- name: Upload build artifacts
|
||||||
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
||||||
with:
|
with:
|
||||||
name: ${{ env.BUILD_DIST_NAME }}
|
name: ${{ steps.sanitize.outputs.result }}
|
||||||
path: ./packages/**/dist
|
path: ./packages/**/dist
|
||||||
if-no-files-found: error
|
if-no-files-found: error
|
||||||
retention-days: 7
|
retention-days: 7
|
||||||
@@ -88,7 +96,7 @@ jobs:
|
|||||||
- name: Download build artifacts
|
- name: Download build artifacts
|
||||||
uses: actions/download-artifact@65d862660abb3549b588b37db4038d3fd1a05f8a # v4.1.8
|
uses: actions/download-artifact@65d862660abb3549b588b37db4038d3fd1a05f8a # v4.1.8
|
||||||
with:
|
with:
|
||||||
name: ${{ env.BUILD_DIST_NAME }}
|
name: ${{ needs.build.outputs.artifact-name }}
|
||||||
path: .
|
path: .
|
||||||
|
|
||||||
- name: Pre publishing changes
|
- name: Pre publishing changes
|
||||||
|
|||||||
Reference in New Issue
Block a user