mirror of
https://github.com/mas-cli/mas
synced 2024-11-21 19:23:01 +00:00
Use posix compliant tail syntax
homebrew allows using gnu coreutils on MacOS. Therefore we should comply with posix standards ```bash $ mas help | tail +3 tail: cannot open '+3' for reading: No such file or directory $ type tail tail is /usr/local/opt/coreutils/libexec/gnubin/tail ``` Switching to posix compliant `-n` syntax is compatible with UNIX and GNU tooling. ```bash $ mas help | /usr/bin/tail -n +3 | wc -l 18 $ mas help | tail -n +3 | wc -l 18 ```
This commit is contained in:
parent
8c0267da3d
commit
7fe27fc693
1 changed files with 1 additions and 1 deletions
|
@ -9,7 +9,7 @@ _mas() {
|
|||
_get_comp_words_by_ref cur prev words cword
|
||||
fi
|
||||
if [[ $cword -eq 1 ]]; then
|
||||
COMPREPLY=($(compgen -W "$(mas help | tail +3 | awk '{print $1}')" -- "$cur"))
|
||||
COMPREPLY=($(compgen -W "$(mas help | tail -n +3 | awk '{print $1}')" -- "$cur"))
|
||||
return 0
|
||||
fi
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue