summaryrefslogtreecommitdiff
path: root/check
diff options
context:
space:
mode:
Diffstat (limited to 'check')
-rwxr-xr-xcheck26
1 files changed, 12 insertions, 14 deletions
diff --git a/check b/check
index c90afee..801c75c 100755
--- a/check
+++ b/check
@@ -3,26 +3,23 @@
set -eu
verbose=false
-if [ "$#" -gt 0 ]
-then
- case "$1" in
+if [ "$#" -gt 0 ]; then
+ case "$1" in
verbose | -v | --verbose)
- verbose=true
- shift
- ;;
- esac
+ verbose=true
+ shift
+ ;;
+ esac
fi
hideok=
-if command -v chronic > /dev/null
-then
- hideok=chronic
+if command -v chronic >/dev/null; then
+ hideok=chronic
fi
-if $verbose
-then
- hideok=
+if $verbose; then
+ hideok=
fi
$hideok cargo check --all-targets
@@ -38,6 +35,7 @@ $hideok subplot docgen jt.md --output jt.pdf
$hideok subplot codegen jt.md --output test.py
rm -f test.log
-$hideok python3 test.py --log test.log "$@"
+target="$(cargo metadata --format-version=1 | jq -r .target_directory)"
+$hideok python3 test.py --log test.log --env "CARGO_TARGET_DIR=$target" "$@"
echo "Everything seems to be in order."