Torsten Bögershausen <[email protected]> writes:
> Sorry for late answer, but there is a problem (both linux and Mac OS X) :-(
> $ make test-lint does not do shel syntax check, neither
> $ make test-lint-shell-syntax
In which directory?
$ make -C t test-lint-shell-syntax
... passes silently ...
$ ed t/t0000-basic.sh
/test_expect_success/
a
which sh
.
w
q
$ make -C t test-lint-shell-syntax
t0000-basic.sh:28: error: which is not portable (please use type):
which sh
make: *** [test-lint-shell-syntax] Error 1
If you edit out '@' (but nothing else) from this line:
> @'$(PERL_PATH_SQ)' check-non-portable-shell.pl $(T)
and run the above again, you would see that it is running this shell
command:
'/usr/bin/perl' check-non-portable-shell.pl t0000-basic.sh t0001-init.sh ...
If you introduce a Perl syntax error to check-non-portable-shell.pl,
like this, you will get:
$ make -C t test-lint-shell-syntax
syntax error at check-non-portable-shell.pl line 11, near "whoa
So... is your shell broken? The above seems to work for dash, bash,
ksh and zsh.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html