Skip to content

Commit

Permalink
Use a shebang to enforce running test.sh in bash
Browse files Browse the repository at this point in the history
Commit b959a7f was made because
`test.sh` cannot run on systems where the default shell is not bash
compatible (e.g. zsh). (cf #23)

A [shebang](https://en.wikipedia.org/wiki/Shebang_(Unix)) allows to
force the use of bash to interpret the shell script. This version
using `/usr/bin/env` should be the most portable.
  • Loading branch information
krtab committed Apr 29, 2024
1 parent c8ec0e0 commit f440573
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ The `gotree` executable should be located in the current folder (or the `$GOPATH

To test the executable:
```
bash test.sh
./test.sh
```

## Auto completion
Expand Down
1 change: 1 addition & 0 deletions test.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#!/usr/bin/env bash
########## Test Suite for Gotree command line tools ##############

set -e
Expand Down

0 comments on commit f440573

Please sign in to comment.