Skip to content

Commit 9352831

Browse files
committed
Simplify CI scripts
1 parent 41b4c1c commit 9352831

File tree

3 files changed

+16
-22
lines changed

3 files changed

+16
-22
lines changed

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,11 @@ matrix:
2222

2323

2424
install:
25-
- bash ci/install.sh
25+
- ci/install.sh
2626
- export PATH="$PATH:$PWD/gcc/bin"
2727

2828
script:
29-
- bash ci/script.sh
29+
- ci/script.sh
3030

3131

3232
cache: cargo

ci/install.sh

100644100755
Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,8 @@
1-
set -euxo pipefail
1+
#!/usr/bin/env bash
22

3-
main() {
4-
if [ $TARGET != x86_64-unknown-linux-gnu ]; then
5-
rustup target add $TARGET
6-
fi
3+
set -euxo pipefail
74

8-
mkdir gcc
9-
curl -L https://static.dev.sifive.com/dev-tools/riscv64-unknown-elf-gcc-8.1.0-2018.12.0-x86_64-linux-ubuntu14.tar.gz | tar --strip-components=1 -C gcc -xz
10-
}
5+
rustup target add $TARGET
116

12-
main
7+
mkdir gcc
8+
curl -L https://static.dev.sifive.com/dev-tools/riscv64-unknown-elf-gcc-8.1.0-2018.12.0-x86_64-linux-ubuntu14.tar.gz | tar --strip-components=1 -C gcc -xz

ci/script.sh

100644100755
Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,13 @@
1-
set -euxo pipefail
1+
#!/usr/bin/env bash
22

3-
main() {
4-
cargo check --target $TARGET
3+
set -euxo pipefail
54

6-
if [ $TRAVIS_RUST_VERSION = nightly ]; then
7-
cargo check --target $TARGET --features inline-asm
8-
fi
5+
cargo check --target $TARGET
96

10-
if [ $TARGET = x86_64-unknown-linux-gnu ]; then
11-
./check-blobs.sh
12-
fi
13-
}
7+
if [ $TRAVIS_RUST_VERSION = nightly ]; then
8+
cargo check --target $TARGET --features inline-asm
9+
fi
1410

15-
main
11+
if [ $TARGET = x86_64-unknown-linux-gnu ]; then
12+
./check-blobs.sh
13+
fi

0 commit comments

Comments
 (0)