Speling nasi fixed some typos.

cdemeijer
2018-07-12 14:20:31 +02:00
parent 5b47f98bee
commit 2819f3e363

@@ -1,6 +1,6 @@
By default, `shellcheck` does not support a `-r` option. The reason for this, is that there are different matching patterns for different files. By default, `shellcheck` does not support a `-r` option. The reason for this, is that there are different matching patterns for different files.
Script could have a `.sh` extension, no extension and have a range of shebang lines (which have there own testing format): Script could have a `.sh` extension, no extension and have a range of shebang lines (which have their own testing format):
* `#!/bin/bash` * `#!/bin/bash`
* `#!/bin/sh` * `#!/bin/sh`
@@ -38,7 +38,7 @@ for file in $(find path/to/scripts -type f -name "*.sh"); do shellcheck --format
## Finding files to test ## Finding files to test
Since not all script have a `.sh` extension, you could use the shebang line of files to determine if they need to be testen (and with which format): Since not all scripts have a `.sh` extension, you could use the shebang line of files to determine if they need to be tested (and with which format):
``` ```
for file in $(grep -IRl "#\!\(/usr/bin/env \|/bin/\)sh" --exclude-dir "var" --exclude "*.txt"); do shellcheck --format=gcc --shell=sh $file; done; for file in $(grep -IRl "#\!\(/usr/bin/env \|/bin/\)sh" --exclude-dir "var" --exclude "*.txt"); do shellcheck --format=gcc --shell=sh $file; done;