Skip to content

Commit 3297ad9

Browse files
authored
Merge pull request #146 from RustCrypto/github-actions/global-env-vars-and-working-dir
.github: use workspace global env vars and working dir
2 parents 4914f48 + 08eb62d commit 3297ad9

17 files changed

+193
-154
lines changed

.github/workflows/blake2.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,14 @@ on:
77
- "Cargo.*"
88
push:
99
branches: master
10-
paths:
11-
- "blake2/**"
12-
- "Cargo.*"
10+
11+
defaults:
12+
run:
13+
working-directory: blake2
14+
15+
env:
16+
CARGO_INCREMENTAL: 0
17+
RUSTFLAGS: "-Dwarnings"
1318

1419
jobs:
1520
build:
@@ -31,7 +36,7 @@ jobs:
3136
target: ${{ matrix.target }}
3237
override: true
3338
- run: cargo build --no-default-features --release --target ${{ matrix.target }}
34-
working-directory: blake2
39+
3540
test:
3641
runs-on: ubuntu-latest
3742
strategy:
@@ -47,9 +52,7 @@ jobs:
4752
toolchain: ${{ matrix.rust }}
4853
override: true
4954
- run: cargo test --no-default-features
50-
working-directory: blake2
5155
- run: cargo test
52-
working-directory: blake2
5356
simd:
5457
runs-on: ubuntu-latest
5558
steps:
@@ -60,8 +63,5 @@ jobs:
6063
toolchain: nightly
6164
override: true
6265
- run: cargo test --features simd
63-
working-directory: blake2
6466
- run: cargo test --features simd_opt
65-
working-directory: blake2
6667
- run: cargo test --features simd_asm
67-
working-directory: blake2

.github/workflows/gost94.yml

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,14 @@ on:
77
- "Cargo.*"
88
push:
99
branches: master
10-
paths:
11-
- "gost94/**"
12-
- "Cargo.*"
10+
11+
defaults:
12+
run:
13+
working-directory: gost94
14+
15+
env:
16+
CARGO_INCREMENTAL: 0
17+
RUSTFLAGS: "-Dwarnings"
1318

1419
jobs:
1520
build:
@@ -30,8 +35,8 @@ jobs:
3035
toolchain: ${{ matrix.rust }}
3136
target: ${{ matrix.target }}
3237
override: true
33-
- working-directory: gost94
34-
run: cargo build --no-default-features --release --target ${{ matrix.target }}
38+
- run: cargo build --no-default-features --release --target ${{ matrix.target }}
39+
3540
test:
3641
runs-on: ubuntu-latest
3742
strategy:
@@ -46,10 +51,8 @@ jobs:
4651
profile: minimal
4752
toolchain: ${{ matrix.rust }}
4853
override: true
49-
- working-directory: gost94
50-
run: |
51-
cargo check --all-features
52-
cargo test --no-default-features
53-
cargo test
54-
cargo test --all-features
54+
- run: cargo check --all-features
55+
- run: cargo test --no-default-features
56+
- run: cargo test
57+
- run: cargo test --all-features
5558

.github/workflows/groestl.yml

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,14 @@ on:
77
- "Cargo.*"
88
push:
99
branches: master
10-
paths:
11-
- "groestl/**"
12-
- "Cargo.*"
10+
11+
defaults:
12+
run:
13+
working-directory: groestl
14+
15+
env:
16+
CARGO_INCREMENTAL: 0
17+
RUSTFLAGS: "-Dwarnings"
1318

1419
jobs:
1520
build:
@@ -30,8 +35,8 @@ jobs:
3035
toolchain: ${{ matrix.rust }}
3136
target: ${{ matrix.target }}
3237
override: true
33-
- working-directory: groestl
34-
run: cargo build --no-default-features --release --target ${{ matrix.target }}
38+
- run: cargo build --no-default-features --release --target ${{ matrix.target }}
39+
3540
test:
3641
runs-on: ubuntu-latest
3742
strategy:
@@ -46,9 +51,7 @@ jobs:
4651
profile: minimal
4752
toolchain: ${{ matrix.rust }}
4853
override: true
49-
- working-directory: groestl
50-
run: |
51-
cargo check --all-features
52-
cargo test --no-default-features
53-
cargo test
54-
cargo test --all-features
54+
- run: cargo check --all-features
55+
- run: cargo test --no-default-features
56+
- run: cargo test
57+
- run: cargo test --all-features

.github/workflows/k12.yml

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,14 @@ on:
77
- "Cargo.*"
88
push:
99
branches: master
10-
paths:
11-
- "k12/**"
12-
- "Cargo.*"
10+
11+
defaults:
12+
run:
13+
working-directory: k12
14+
15+
env:
16+
CARGO_INCREMENTAL: 0
17+
RUSTFLAGS: "-Dwarnings"
1318

1419
jobs:
1520
build:
@@ -30,8 +35,8 @@ jobs:
3035
toolchain: ${{ matrix.rust }}
3136
target: ${{ matrix.target }}
3237
override: true
33-
- working-directory: k12
34-
run: cargo build --no-default-features --release --target ${{ matrix.target }}
38+
- run: cargo build --no-default-features --release --target ${{ matrix.target }}
39+
3540
test:
3641
runs-on: ubuntu-latest
3742
strategy:
@@ -46,10 +51,8 @@ jobs:
4651
profile: minimal
4752
toolchain: ${{ matrix.rust }}
4853
override: true
49-
- working-directory: k12
50-
run: |
51-
cargo check --all-features
52-
cargo test --no-default-features
53-
cargo test
54-
cargo test --all-features
54+
- run: cargo check --all-features
55+
- run: cargo test --no-default-features
56+
- run: cargo test
57+
- run: cargo test --all-features
5558

.github/workflows/md2.yml

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,14 @@ on:
77
- "Cargo.*"
88
push:
99
branches: master
10-
paths:
11-
- "md2/**"
12-
- "Cargo.*"
10+
11+
defaults:
12+
run:
13+
working-directory: md2
14+
15+
env:
16+
CARGO_INCREMENTAL: 0
17+
RUSTFLAGS: "-Dwarnings"
1318

1419
jobs:
1520
build:
@@ -30,8 +35,8 @@ jobs:
3035
toolchain: ${{ matrix.rust }}
3136
target: ${{ matrix.target }}
3237
override: true
33-
- working-directory: md2
34-
run: cargo build --no-default-features --release --target ${{ matrix.target }}
38+
- run: cargo build --no-default-features --release --target ${{ matrix.target }}
39+
3540
test:
3641
runs-on: ubuntu-latest
3742
strategy:
@@ -46,10 +51,8 @@ jobs:
4651
profile: minimal
4752
toolchain: ${{ matrix.rust }}
4853
override: true
49-
- working-directory: md2
50-
run: |
51-
cargo check --all-features
52-
cargo test --no-default-features
53-
cargo test
54-
cargo test --all-features
54+
- run: cargo check --all-features
55+
- run: cargo test --no-default-features
56+
- run: cargo test
57+
- run: cargo test --all-features
5558

.github/workflows/md4.yml

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,14 @@ on:
77
- "Cargo.*"
88
push:
99
branches: master
10-
paths:
11-
- "md4/**"
12-
- "Cargo.*"
10+
11+
defaults:
12+
run:
13+
working-directory: md4
14+
15+
env:
16+
CARGO_INCREMENTAL: 0
17+
RUSTFLAGS: "-Dwarnings"
1318

1419
jobs:
1520
build:
@@ -30,8 +35,8 @@ jobs:
3035
toolchain: ${{ matrix.rust }}
3136
target: ${{ matrix.target }}
3237
override: true
33-
- working-directory: md4
34-
run: cargo build --no-default-features --release --target ${{ matrix.target }}
38+
- run: cargo build --no-default-features --release --target ${{ matrix.target }}
39+
3540
test:
3641
runs-on: ubuntu-latest
3742
strategy:
@@ -46,10 +51,8 @@ jobs:
4651
profile: minimal
4752
toolchain: ${{ matrix.rust }}
4853
override: true
49-
- working-directory: md4
50-
run: |
51-
cargo check --all-features
52-
cargo test --no-default-features
53-
cargo test
54-
cargo test --all-features
54+
- run: cargo check --all-features
55+
- run: cargo test --no-default-features
56+
- run: cargo test
57+
- run: cargo test --all-features
5558

.github/workflows/md5.yml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,14 @@ on:
1111
- "md5/**"
1212
- "Cargo.*"
1313

14+
defaults:
15+
run:
16+
working-directory: md5
17+
18+
env:
19+
CARGO_INCREMENTAL: 0
20+
RUSTFLAGS: "-Dwarnings"
21+
1422
jobs:
1523
build:
1624
runs-on: ubuntu-latest
@@ -31,7 +39,7 @@ jobs:
3139
target: ${{ matrix.target }}
3240
override: true
3341
- run: cargo build --no-default-features --release --target ${{ matrix.target }}
34-
working-directory: md5
42+
3543
test:
3644
runs-on: ubuntu-latest
3745
strategy:
@@ -47,10 +55,6 @@ jobs:
4755
toolchain: ${{ matrix.rust }}
4856
override: true
4957
- run: cargo check
50-
working-directory: md5
5158
- run: cargo test --no-default-features
52-
working-directory: md5
5359
- run: cargo test
54-
working-directory: md5
5560
- run: cargo test --features asm
56-
working-directory: md5

.github/workflows/ripemd160.yml

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,14 @@ on:
77
- "Cargo.*"
88
push:
99
branches: master
10-
paths:
11-
- "ripemd160/**"
12-
- "Cargo.*"
10+
11+
defaults:
12+
run:
13+
working-directory: ripemd160
14+
15+
env:
16+
CARGO_INCREMENTAL: 0
17+
RUSTFLAGS: "-Dwarnings"
1318

1419
jobs:
1520
build:
@@ -30,8 +35,8 @@ jobs:
3035
toolchain: ${{ matrix.rust }}
3136
target: ${{ matrix.target }}
3237
override: true
33-
- working-directory: ripemd160
34-
run: cargo build --no-default-features --release --target ${{ matrix.target }}
38+
- run: cargo build --no-default-features --release --target ${{ matrix.target }}
39+
3540
test:
3641
runs-on: ubuntu-latest
3742
strategy:
@@ -46,10 +51,8 @@ jobs:
4651
profile: minimal
4752
toolchain: ${{ matrix.rust }}
4853
override: true
49-
- working-directory: ripemd160
50-
run: |
51-
cargo check --all-features
52-
cargo test --no-default-features
53-
cargo test
54-
cargo test --all-features
54+
- run: cargo check --all-features
55+
- run: cargo test --no-default-features
56+
- run: cargo test
57+
- run: cargo test --all-features
5558

.github/workflows/ripemd320.yml

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,14 @@ on:
77
- "Cargo.*"
88
push:
99
branches: master
10-
paths:
11-
- "ripemd320/**"
12-
- "Cargo.*"
10+
11+
defaults:
12+
run:
13+
working-directory: ripemd320
14+
15+
env:
16+
CARGO_INCREMENTAL: 0
17+
RUSTFLAGS: "-Dwarnings"
1318

1419
jobs:
1520
build:
@@ -30,8 +35,8 @@ jobs:
3035
toolchain: ${{ matrix.rust }}
3136
target: ${{ matrix.target }}
3237
override: true
33-
- working-directory: ripemd320
34-
run: cargo build --no-default-features --release --target ${{ matrix.target }}
38+
- run: cargo build --no-default-features --release --target ${{ matrix.target }}
39+
3540
test:
3641
runs-on: ubuntu-latest
3742
strategy:
@@ -46,10 +51,7 @@ jobs:
4651
profile: minimal
4752
toolchain: ${{ matrix.rust }}
4853
override: true
49-
- working-directory: ripemd320
50-
run: |
51-
cargo check --all-features
52-
cargo test --no-default-features
53-
cargo test
54-
cargo test --all-features
55-
54+
- run: cargo check --all-features
55+
- run: cargo test --no-default-features
56+
- run: cargo test
57+
- run: cargo test --all-features

0 commit comments

Comments
 (0)