Skip to content

Commit a6d1db8

Browse files
authored
chore(ci): Bump crates before publishing (#9308)
**Related issue:** - Closes #9304
1 parent 7514d9b commit a6d1db8

File tree

2 files changed

+39
-5
lines changed

2 files changed

+39
-5
lines changed

.github/workflows/publish.yml

Lines changed: 35 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,44 @@ concurrency:
4040
cancel-in-progress: true
4141

4242
jobs:
43+
cargo-bump:
44+
name: "Bump crates"
45+
runs-on: ubuntu-latest
46+
steps:
47+
- uses: actions/checkout@v4
48+
49+
- uses: actions-rs/toolchain@v1
50+
with:
51+
profile: minimal
52+
53+
- name: Install cargo-edit
54+
uses: baptiste0928/[email protected]
55+
with:
56+
crate: cargo-edit
57+
version: "0.12.2"
58+
locked: true
59+
60+
- name: Install cargo-mono
61+
uses: baptiste0928/[email protected]
62+
with:
63+
crate: cargo-mono
64+
version: "0.3.7"
65+
66+
- run: cargo bump
67+
68+
- uses: webfactory/[email protected]
69+
with:
70+
ssh-private-key: ${{ secrets.SWC_BOT_SSH }}
71+
72+
- name: Push bump commit
73+
run: |
74+
git push [email protected]:swc-project/swc.git --no-verify
75+
4376
publish-cargo:
4477
name: "Publish cargo crates"
4578
runs-on: ubuntu-latest
79+
needs:
80+
- cargo-bump
4681
steps:
4782
- uses: actions/checkout@v4
4883

@@ -64,7 +99,6 @@ jobs:
6499
with:
65100
crate: cargo-mono
66101
version: "0.3.7"
67-
locked: true
68102

69103
- name: Update constant of swc_core
70104
run: npx ts-node .github/bot/src/cargo/update-constants.ts

Cargo.lock

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)