Provide Makefile to check for syntax error

Verify the script can be executed via netscript-unit-test
before triggering script upload
ksolomko/vlan
Michael Prokop 12 years ago
parent 1d2f4b66eb
commit bce521dad0

@ -0,0 +1,15 @@
# for syntax checks
BASH_SCRIPTS = deployment.sh
syntaxcheck: shellcheck
shellcheck:
@echo -n "Checking for shell syntax errors"; \
for SCRIPT in $(BASH_SCRIPTS); do \
test -r $${SCRIPT} || continue ; \
bash -n $${SCRIPT} || exit ; \
echo -n "."; \
done; \
echo " done."; \
# EOF
Loading…
Cancel
Save