Skip to content
This repository was archived by the owner on Jan 22, 2025. It is now read-only.

Commit be5f2ef

Browse files
committed
Consolidate CI jobs
1 parent adfcb79 commit be5f2ef

10 files changed

Lines changed: 53 additions & 70 deletions

ci/buildkite.yml

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,28 +2,22 @@ steps:
22
- command: "ci/docker-run.sh rust ci/test-stable.sh"
33
name: "stable [public]"
44
timeout_in_minutes: 20
5+
- command: "ci/shellcheck.sh"
6+
name: "shellcheck [public]"
7+
timeout_in_minutes: 20
58
- wait
69
- command: "ci/docker-run.sh rustlang/rust:nightly ci/test-nightly.sh"
710
name: "nightly [public]"
811
timeout_in_minutes: 20
9-
- command: "ci/docker-run.sh rust ci/test-ignored.sh"
10-
name: "ignored [public]"
11-
timeout_in_minutes: 20
12-
- command: "ci/test-cuda.sh"
13-
name: "cuda [public]"
12+
- command: "ci/test-stable-perf.sh"
13+
name: "stable-perf [public]"
1414
timeout_in_minutes: 20
1515
retry:
1616
automatic:
1717
- exit_status: "*"
1818
limit: 2
1919
agents:
2020
- "queue=cuda"
21-
- command: "ci/shellcheck.sh"
22-
name: "shellcheck [public]"
23-
timeout_in_minutes: 20
24-
- command: "ci/docker-run.sh rust ci/test-erasure.sh"
25-
name: "erasure [public]"
26-
timeout_in_minutes: 20
2721
- command: "ci/snap.sh [public]"
2822
timeout_in_minutes: 20
2923
name: "snap [public]"

ci/coverage.sh

Lines changed: 0 additions & 18 deletions
This file was deleted.

ci/docker-run.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,4 +47,4 @@ ARGS+=(
4747
)
4848

4949
set -x
50-
docker run "${ARGS[@]}" "$IMAGE" "$@"
50+
exec docker run "${ARGS[@]}" "$IMAGE" "$@"

ci/run-local.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ if [[ ! -x $BKRUN ]]; then
1616
fi
1717

1818
set -x
19-
./ci/node_modules/.bin/bkrun ci/buildkite.yml
19+
exec ./ci/node_modules/.bin/bkrun ci/buildkite.yml

ci/snap.sh

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,11 @@ else
1313
SNAP_CHANNEL=beta
1414
fi
1515

16-
if [[ -n $SNAPCRAFT_CREDENTIALS_KEY ]]; then
16+
if [[ -z $DRYRUN ]]; then
17+
[[ -n $SNAPCRAFT_CREDENTIALS_KEY ]] || {
18+
echo SNAPCRAFT_CREDENTIALS_KEY not defined
19+
exit 1;
20+
}
1721
(
1822
openssl aes-256-cbc -d \
1923
-in ci/snapcraft.credentials.enc \
@@ -28,5 +32,9 @@ if [[ -n $SNAPCRAFT_CREDENTIALS_KEY ]]; then
2832
fi
2933

3034
set -x
35+
36+
echo --- build
3137
snapcraft
38+
39+
echo --- publish
3240
$DRYRUN snapcraft push solana_*.snap --release $SNAP_CHANNEL

ci/test-erasure.sh

Lines changed: 0 additions & 13 deletions
This file was deleted.

ci/test-ignored.sh

Lines changed: 0 additions & 9 deletions
This file was deleted.

ci/test-nightly.sh

Lines changed: 24 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,31 @@
22

33
cd "$(dirname "$0")/.."
44

5+
export RUST_BACKTRACE=1
56
rustc --version
67
cargo --version
78

8-
export RUST_BACKTRACE=1
9-
cargo build --verbose --features unstable
10-
cargo test --verbose --features unstable
11-
cargo bench --verbose --features unstable
12-
ci/coverage.sh
9+
_() {
10+
echo "--- $*"
11+
"$@"
12+
}
13+
14+
_ cargo build --verbose --features unstable
15+
_ cargo test --verbose --features unstable
16+
_ cargo bench --verbose --features unstable
17+
18+
19+
# Coverage ...
20+
_ cargo install --force cargo-cov
21+
_ cargo cov test
22+
_ cargo cov report
23+
24+
echo --- Coverage report:
25+
ls -l target/cov/report/index.html
26+
27+
if [[ -z "$CODECOV_TOKEN" ]]; then
28+
echo CODECOV_TOKEN undefined
29+
else
30+
bash <(curl -s https://codecov.io/bash) -x 'llvm-cov gcov'
31+
fi
1332

14-
exit 0

ci/test-cuda.sh renamed to ci/test-stable-perf.sh

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,9 @@ cd "$(dirname "$0")/.."
44

55
./fetch-perf-libs.sh
66

7-
export LD_LIBRARY_PATH=/usr/local/cuda/lib64
7+
export LD_LIBRARY_PATH=$PWD:/usr/local/cuda/lib64
88
export PATH=$PATH:/usr/local/cuda/bin
9-
109
export RUST_BACKTRACE=1
11-
cargo test --features=cuda
1210

13-
exit 0
11+
set -x
12+
exec cargo test --features=cuda,erasure

ci/test-stable.sh

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,17 @@
22

33
cd "$(dirname "$0")/.."
44

5+
export RUST_BACKTRACE=1
56
rustc --version
67
cargo --version
78

8-
export RUST_BACKTRACE=1
9-
rustup component add rustfmt-preview
10-
cargo fmt -- --write-mode=diff
11-
cargo build --verbose
12-
cargo test --verbose
9+
_() {
10+
echo "--- $*"
11+
"$@"
12+
}
1313

14-
exit 0
14+
_ rustup component add rustfmt-preview
15+
_ cargo fmt -- --write-mode=diff
16+
_ cargo build --verbose
17+
_ cargo test --verbose
18+
_ cargo test -- --ignored

0 commit comments

Comments
 (0)