Skip to content

Commit 6b0ccd2

Browse files
authored
ci: fix vendoring pipeline (#7316)
The vendoring validation would happen if dev dependencies were updated. These would not create a bundle and that caused issues. The major updates were also not taken into account for vendoring and that is now the case. Instead of relying on the group, we verify what files are changed.
1 parent b1c41b8 commit 6b0ccd2

File tree

3 files changed

+25
-11
lines changed

3 files changed

+25
-11
lines changed
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Validate vendored bundle
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- 'vendor/**'
7+
push:
8+
branches: [master]
9+
paths:
10+
- 'vendor/**'
11+
workflow_dispatch:
12+
13+
jobs:
14+
validate-vendored-bundle:
15+
runs-on: ubuntu-latest
16+
permissions:
17+
contents: read
18+
steps:
19+
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
20+
- uses: ./.github/actions/node/active-lts
21+
# Running `yarn` also automatically runs Rspack as a postinstall script.
22+
- run: yarn --frozen-lockfile
23+
working-directory: vendor
24+
- run: git diff --exit-code

.github/workflows/dependabot-automation.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ jobs:
6262
run: |
6363
set -euo pipefail
6464
65-
echo "is_vendor_group=${{ steps.metadata.outputs.dependency-group == 'vendor-minor-and-patch-dependencies' }}" >> $GITHUB_OUTPUT
65+
echo "is_vendor_group=${{ steps.metadata.outputs.directory == '/vendor' && steps.metadata.outputs.dependency-type == 'direct:production' }}" >> $GITHUB_OUTPUT
6666
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
6767
if: steps.ctx.outputs.is_vendor_group == 'true'
6868
with:

.github/workflows/platform.yml

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -62,16 +62,6 @@ jobs:
6262
- run: ./node_modules/.bin/bun pm pack --gzip-level 0 --filename bun.tgz && tar -zxf bun.tgz -C bun
6363
- run: diff -r npm bun
6464

65-
bundle-validate:
66-
runs-on: ubuntu-latest
67-
steps:
68-
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
69-
- uses: ./.github/actions/node/active-lts
70-
# Running `yarn` also automatically runs Rspack as a postinstall script.
71-
- run: yarn --frozen-lockfile
72-
working-directory: vendor
73-
- run: git diff --exit-code
74-
7565
core:
7666
runs-on: ubuntu-latest
7767
steps:

0 commit comments

Comments
 (0)