Skip to content

Commit 6061176

Browse files
committed
ci: Auto update Github Action workflows
1 parent 4c47bc7 commit 6061176

File tree

4 files changed

+34
-19
lines changed

4 files changed

+34
-19
lines changed

.github/workflows/module-ci.yml

Lines changed: 21 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
# v3.800.23
2-
# https://virtocommerce.atlassian.net/browse/VCST-3056
1+
# v3.800.24
2+
# https://virtocommerce.atlassian.net/browse/VCST-4487
33
name: Module CI
44

55
on:
@@ -154,11 +154,26 @@ jobs:
154154
blobSAS: ${{ secrets.BLOB_TOKEN }}
155155
blobUrl: ${{ vars.BLOB_URL }}
156156

157+
- name: Sanitize branch name
158+
if: ${{ github.event_name == 'pull_request' }}
159+
id: sanitize_branch
160+
env:
161+
BRANCH_NAME: ${{ github.head_ref }}
162+
run: |
163+
# Keep only alphanumeric, hyphens, underscores, and forward slashes and limit length to 255 characters.
164+
SANITIZED_BRANCH=$(printf '%s\n' "$BRANCH_NAME" | sed 's/[^-a-zA-Z0-9_/]//g' | cut -c1-255)
165+
if [ -z "$SANITIZED_BRANCH" ]; then
166+
echo "branch name is empty"
167+
exit 1
168+
else
169+
echo "branchName=$SANITIZED_BRANCH" >> $GITHUB_OUTPUT
170+
fi
171+
157172
- name: Add Jira link
158173
if: ${{ github.event_name == 'pull_request' }}
159174
uses: VirtoCommerce/vc-github-actions/publish-jira-link@master
160175
with:
161-
branchName: ${{ github.head_ref }}
176+
branchName: ${{ steps.sanitize_branch.outputs.branchName }}
162177
repoOrg: ${{ github.repository_owner }}
163178
env:
164179
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -309,7 +324,7 @@ jobs:
309324
if: ${{ ((github.ref == 'refs/heads/dev') && (github.event_name == 'push')) ||
310325
(github.event_name == 'workflow_dispatch') || ((github.base_ref == 'dev') && (github.event_name == 'pull_request')) }}
311326
needs: 'ci'
312-
uses: VirtoCommerce/.github/.github/workflows/ui-autotests.yml@v3.800.23
327+
uses: VirtoCommerce/.github/.github/workflows/ui-autotests.yml@v3.800.24
313328
with:
314329
installModules: 'false'
315330
installCustomModule: 'true'
@@ -327,7 +342,7 @@ jobs:
327342
if: ${{ ((github.ref == 'refs/heads/dev') && (github.event_name == 'push') && (needs.ci.outputs.run-e2e == 'true')) ||
328343
(github.event_name == 'workflow_dispatch') || (github.base_ref == 'dev') && (github.event_name == 'pull_request') }}
329344
needs: 'ci'
330-
uses: VirtoCommerce/.github/.github/workflows/e2e.yml@v3.800.23
345+
uses: VirtoCommerce/.github/.github/workflows/e2e.yml@v3.800.24
331346
with:
332347
katalonRepo: 'VirtoCommerce/vc-quality-gate-katalon'
333348
katalonRepoBranch: 'dev'
@@ -348,7 +363,7 @@ jobs:
348363
&& github.event_name == 'push'
349364
&& needs.ci.outputs.deployment-folder-exists == 'true'}}
350365
needs: ci
351-
uses: VirtoCommerce/.github/.github/workflows/deploy-cloud.yml@v3.800.23
366+
uses: VirtoCommerce/.github/.github/workflows/deploy-cloud.yml@v3.800.24
352367
with:
353368
releaseSource: module
354369
moduleId: ${{ needs.ci.outputs.moduleId }}

.github/workflows/module-release-hotfix.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
# v3.800.23
2-
# https://virtocommerce.atlassian.net/browse/VCST-3056
1+
# v3.800.24
2+
# https://virtocommerce.atlassian.net/browse/VCST-4487
33
name: Release hotfix
44

55
on:
@@ -13,12 +13,12 @@ on:
1313

1414
jobs:
1515
test:
16-
uses: VirtoCommerce/.github/.github/workflows/test-and-sonar.yml@v3.800.23
16+
uses: VirtoCommerce/.github/.github/workflows/test-and-sonar.yml@v3.800.24
1717
secrets:
1818
sonarToken: ${{ secrets.SONAR_TOKEN }}
1919

2020
build:
21-
uses: VirtoCommerce/.github/.github/workflows/build.yml@v3.800.23
21+
uses: VirtoCommerce/.github/.github/workflows/build.yml@v3.800.24
2222
with:
2323
uploadPackage: 'true'
2424
uploadDocker: 'false'
@@ -46,7 +46,7 @@ jobs:
4646
publish-github-release:
4747
needs:
4848
[build, test, get-metadata]
49-
uses: VirtoCommerce/.github/.github/workflows/publish-github.yml@v3.800.23
49+
uses: VirtoCommerce/.github/.github/workflows/publish-github.yml@v3.800.24
5050
with:
5151
fullKey: ${{ needs.build.outputs.packageFullKey }}
5252
changeLog: '${{ needs.get-metadata.outputs.changeLog }}'

.github/workflows/publish-nugets.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
# v3.800.23
2-
# https://virtocommerce.atlassian.net/browse/VCST-3056
1+
# v3.800.24
2+
# https://virtocommerce.atlassian.net/browse/VCST-4487
33
name: Publish nuget
44

55
on:
@@ -13,12 +13,12 @@ on:
1313

1414
jobs:
1515
test:
16-
uses: VirtoCommerce/.github/.github/workflows/test-and-sonar.yml@v3.800.23
16+
uses: VirtoCommerce/.github/.github/workflows/test-and-sonar.yml@v3.800.24
1717
secrets:
1818
sonarToken: ${{ secrets.SONAR_TOKEN }}
1919

2020
build:
21-
uses: VirtoCommerce/.github/.github/workflows/build.yml@v3.800.23
21+
uses: VirtoCommerce/.github/.github/workflows/build.yml@v3.800.24
2222
with:
2323
uploadPackage: 'true'
2424
uploadDocker: 'false'
@@ -29,7 +29,7 @@ jobs:
2929
publish-nuget:
3030
needs:
3131
[build, test]
32-
uses: VirtoCommerce/.github/.github/workflows/publish-github.yml@v3.800.23
32+
uses: VirtoCommerce/.github/.github/workflows/publish-github.yml@v3.800.24
3333
with:
3434
fullKey: ${{ needs.build.outputs.packageFullKey }}
3535
forceGithub: false

.github/workflows/release.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
# v3.800.23
2-
# https://virtocommerce.atlassian.net/browse/VCST-3056
1+
# v3.800.24
2+
# https://virtocommerce.atlassian.net/browse/VCST-4487
33
name: Release
44

55
on:
66
workflow_dispatch:
77

88
jobs:
99
release:
10-
uses: VirtoCommerce/.github/.github/workflows/release.yml@v3.800.23
10+
uses: VirtoCommerce/.github/.github/workflows/release.yml@v3.800.24
1111
secrets:
1212
envPAT: ${{ secrets.REPO_TOKEN }}

0 commit comments

Comments
 (0)