summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2020-04-10 13:38:33 +0300
committerLars Wirzenius <liw@liw.fi>2020-04-10 13:38:33 +0300
commitb4ebf05f45930de4fc5ebef6352e635c6e8ea91b (patch)
tree83f3dc19763fb3627755acca2e09a9e0d7a73ee7
parentf77f1ae0faf4a527841c2e48163d8e357e8f63ac (diff)
downloadvmdb2-b4ebf05f45930de4fc5ebef6352e635c6e8ea91b.tar.gz
Change: ./check to run yarn only if yarnutils is installed
On the version of cmdtest (in which yarn is) there is no yarnutils. Since yarn is on its way to the dung heap of my obsolete projects, there's no point in doing a backport of cmdtest. Better put that energy into improving Subplot.
-rwxr-xr-xcheck21
1 files changed, 10 insertions, 11 deletions
diff --git a/check b/check
index e9cdfac..43f671a 100755
--- a/check
+++ b/check
@@ -14,19 +14,19 @@ then
echo
fi
-if false; then
echo Running yarn tests ========================================
-yarn \
- --shell=python3 \
- --shell-arg '' \
- --shell-library yarns/lib.py \
- --env "PYTHONPATH=$(pwd)/yarns" \
- --cd-datadir \
- yarns/*.yarn "$@"
-echo
+if python3 -c 'import yarnutils' 2>/dev/null
+then
+ yarn \
+ --shell=python3 \
+ --shell-arg '' \
+ --shell-library yarns/lib.py \
+ --env "PYTHONPATH=$(pwd)/yarns" \
+ --cd-datadir \
+ yarns/*.yarn "$@"
+ echo
fi
-if false; then
echo Formatting docs ========================================
./format.sh
@@ -54,4 +54,3 @@ if ! diff -u <(steps) <(steps | sort)
then
panic "Steps are not in sorted order"
fi
-fi