pvscheck: Add help

This commit is contained in:
ZyX 2017-04-10 13:41:09 +03:00
parent ebfcf2fa38
commit 59f0cbc282

View File

@ -64,9 +64,25 @@ patch_sources() {
-exec /bin/sh -c "$sh_script" - '{}' \;
}
help() {
echo 'Usage: pvscheck.sh [target-directory [branch]]'
echo
echo ' target-directory: Directory where build should occur'
echo ' Default: ../neovim-pvs'
echo
echo ' branch: Branch to check'
echo ' Must not be already checked out: uses git worktree.'
echo ' Default: master'
}
main() {
local PVS_URL="http://files.viva64.com/pvs-studio-6.14.21446.1-x86_64.tgz"
if test "x$1" = "x--help" ; then
help
return 0
fi
local tgt="${1:-$PWD/../neovim-pvs}"
local branch="${2:-master}"