bin/cli can be called from an endpoint's spec folder
For example, if you git clone --recursive https://tildegit.org/forge/endpoints.php you can cd endpoints.php/spec && ./test_tests_web.sh and it will work
This commit is contained in:
parent
fd0ac6a610
commit
47ee90cd54
7
bin/cli
7
bin/cli
|
@ -1,9 +1,12 @@
|
|||
#! /usr/bin/env bash
|
||||
|
||||
ORIGDIR="$(pwd)"
|
||||
SCRIPTDIR="$(dirname "$0")"
|
||||
BASEDIR="$(realpath "$SCRIPTDIR"/..)"
|
||||
|
||||
if [ -f "$BASEDIR"/target/release/whck ]; then
|
||||
cd "$BASEDIR"
|
||||
|
||||
if [ -f target/release/whck ]; then
|
||||
output="$(cargo build --release 2>&1)"
|
||||
if [ $? -eq 0 ]; then
|
||||
# Build succeeded echo path to binary
|
||||
|
@ -21,3 +24,5 @@ else
|
|||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
cd "$ORIGDIR"
|
||||
|
|
Loading…
Reference in New Issue