diff options
-rwxr-xr-x | doit.sh | 9 |
1 files changed, 5 insertions, 4 deletions
@@ -6,13 +6,14 @@ else command="perl -I/home/dakkar/src/WebCoso/lib/ /home/dakkar/src/WebCoso/script/webcoso.pl" fi -$command -s src/ -d output -I templates/ "$@" +if ! $command -s src/ -d output -I templates/ "$@"; then + echo "Something wrong: $!" >&2 + exit 1 +fi -if [[ $! -eq 0 && -z "$*" ]]; then +if [[ "$*" != '--clean' ]]; then rsync -r output/ /var/www/localhost/htdocs/ rsync -r additions/ /var/www/localhost/htdocs/ -else - echo "Something wrong: $!" >&2 fi |