-
Notifications
You must be signed in to change notification settings - Fork 31
/
.buildbot.sh
39 lines (29 loc) · 1.01 KB
/
.buildbot.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#! /bin/sh
set -e
export CARGO_HOME="`pwd`/.cargo"
export RUSTUP_HOME="`pwd`/.rustup"
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs > rustup.sh
sh rustup.sh --default-host x86_64-unknown-linux-gnu --default-toolchain stable -y --no-modify-path
export PATH=`pwd`/.cargo/bin/:$PATH
cargo fmt --all -- --check
rustup toolchain install stable
rustup default stable
cargo test
cargo test --release
cargo test --lib cfgrammar --features serde
cargo test --lib lrpar --features serde
root=`pwd`
cd $root/lrlex/examples/calc_manual_lex
echo "2 + 3 * 4" | cargo run | grep "Result: 14"
cd $root/lrpar/examples/calc_actions
echo "2 + 3 * 4" | cargo run | grep "Result: 14"
cd $root/lrpar/examples/calc_ast
echo "2 + 3 * 4" | cargo run | grep "Result: 14"
cd $root/lrpar/examples/calc_parsetree
echo "2 + 3 * 4" | cargo run | grep "Result: 14"
cd $root
RUSTDOCFLAGS="-Dwarnings" cargo doc --no-deps
which cargo-deny | cargo install cargo-deny || true
if [ "X`which cargo-deny`" != "X"]; then
cargo-deny check license
fi