Skip to content

Commit 28a376e

Browse files
committed
small CI improvements
1 parent f538094 commit 28a376e

File tree

2 files changed

+15
-16
lines changed

2 files changed

+15
-16
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ concurrency:
99
group: ${{ github.workflow }}-${{ github.ref }}
1010
cancel-in-progress: true
1111

12-
# Limit permissions of the GITHUB_TOKEN
12+
# Do not add permissions here! Configure them at the job level!
1313
permissions:
1414
contents: read
1515

@@ -38,9 +38,6 @@ jobs:
3838
with:
3939
version: 0.15.2
4040

41-
- name: Install Rust
42-
uses: dtolnay/rust-toolchain@stable
43-
4441
- name: Install expect (Ubuntu)
4542
if: startsWith(matrix.os, 'ubuntu-')
4643
run: sudo apt-get install -y expect

.github/workflows/release.yml

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,13 @@ concurrency:
1414
group: ${{ github.workflow }}-${{ github.ref }}
1515
cancel-in-progress: true
1616

17-
# Limit permissions of the GITHUB_TOKEN (override at job level as needed)
17+
# Do not add permissions here! Configure them at the job level!
1818
permissions:
1919
contents: read
2020

21+
env:
22+
ZIG_VERSION: 0.15.2
23+
2124
jobs:
2225
build-and-bundle:
2326
name: Build and Bundle Platform
@@ -33,14 +36,16 @@ jobs:
3336
uses: actions/checkout@v4
3437

3538
- name: Install Zig
36-
uses: mlugg/setup-zig@v2
39+
uses: mlugg/setup-zig@8d6198c65fb0feaa111df26e6b467fea8345e46f # ratchet:mlugg/setup-zig@v2.0.5
3740
with:
38-
version: 0.15.2
41+
version: ${{ env.ZIG_VERSION }}
3942

40-
- name: Install Rust with cross-compilation targets
41-
uses: dtolnay/rust-toolchain@stable
42-
with:
43-
targets: x86_64-apple-darwin,aarch64-apple-darwin,x86_64-unknown-linux-musl,aarch64-unknown-linux-musl
43+
- name: Install Rust cross-compilation targets
44+
run: |
45+
rustup target add x86_64-apple-darwin
46+
rustup target add aarch64-apple-darwin
47+
rustup target add x86_64-unknown-linux-musl
48+
rustup target add aarch64-unknown-linux-musl
4449
4550
- name: Build Roc from pinned commit
4651
run: |
@@ -109,12 +114,9 @@ jobs:
109114
uses: actions/checkout@v4
110115

111116
- name: Install Zig
112-
uses: mlugg/setup-zig@v2
117+
uses: mlugg/setup-zig@8d6198c65fb0feaa111df26e6b467fea8345e46f # ratchet:mlugg/setup-zig@v2.0.5
113118
with:
114-
version: 0.15.2
115-
116-
- name: Install Rust
117-
uses: dtolnay/rust-toolchain@stable
119+
version: ${{ env.ZIG_VERSION }}
118120

119121
- name: Install expect (Ubuntu)
120122
if: startsWith(matrix.os, 'ubuntu-')

0 commit comments

Comments
 (0)