forked from davisking/dlib
-
Notifications
You must be signed in to change notification settings - Fork 0
/
testenv
executable file
·31 lines (24 loc) · 881 Bytes
/
testenv
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
#/bin/sh
#
#This script checks to make sure all the commands we need are
#present
return_error()
{
echo "Error, can't run the $1 command"
exit 1
}
echo Testing environment for needed utilities
bc -h > /dev/null || return_error "bc";
echo nothing | awk '{}' > /dev/null || return_error "awk";
echo | sed -e "s/s/r/" > /dev/null || return_error "sed";
htmlify > /dev/null || return_error "htmlify";
echo | xargs > /dev/null || return_error "xargs";
hg > /dev/null || return_error "hg";
xsltproc -V > /dev/null || return_error "xsltproc";
tar --help > /dev/null || return_error "tar";
zip -h > /dev/null || return_error "zip";
bzip2 -h &> /dev/null || return_error "bzip2";
pygmentize -h &> /dev/null || return_error "pygmentize";
which sphinx-build &> /dev/null || return_error "sphinx-build";
echo All needed utilities found
exit 0