Skip to content

Commit 642ef29

Browse files
committed
Update CI scripts
1 parent fc79de9 commit 642ef29

File tree

3 files changed

+22
-30
lines changed

3 files changed

+22
-30
lines changed

riscv-rt/.travis.yml

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,11 @@ env:
1313

1414
if: (branch = staging OR branch = trying OR branch = master) OR (type = pull_request AND branch = master)
1515

16-
before_install: set -e
17-
1816
install:
19-
- bash ci/install.sh
20-
- export PATH="$PATH:$PWD/gcc/bin"
17+
- ci/install.sh
2118

2219
script:
23-
- bash ci/script.sh
24-
25-
after_script: set +e
20+
- ci/script.sh
2621

2722
cache: cargo
2823

riscv-rt/ci/install.sh

100644100755
Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,10 @@
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+
if [ $TARGET != x86_64-unknown-linux-gnu ]; then
6+
rustup target add $TARGET
7+
fi
118

12-
main
9+
mkdir gcc
10+
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

riscv-rt/ci/script.sh

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

3-
main() {
4-
cargo check --target $TARGET
5-
if [[ $TARGET == riscv* ]]; then
6-
cargo check --target $TARGET --examples
7-
fi
3+
set -euxo pipefail
84

9-
if [ $TRAVIS_RUST_VERSION = nightly ]; then
10-
cargo check --target $TARGET --features 'inline-asm'
11-
fi
5+
cargo check --target $TARGET
6+
if [[ $TARGET == riscv* ]]; then
7+
cargo check --target $TARGET --examples
8+
fi
129

13-
if [ $TARGET = x86_64-unknown-linux-gnu ]; then
14-
./check-blobs.sh
15-
fi
16-
}
10+
if [ $TRAVIS_RUST_VERSION = nightly ]; then
11+
cargo check --target $TARGET --features 'inline-asm'
12+
fi
1713

18-
main
14+
if [ $TARGET = x86_64-unknown-linux-gnu ]; then
15+
PATH="$PATH:$PWD/gcc/bin"
16+
./check-blobs.sh
17+
fi

0 commit comments

Comments
 (0)