mirror of
https://gitlab.alpinelinux.org/alpine/abuild.git
synced 2024-12-31 19:32:06 +00:00
apkgrel: --clean-git enhancements
This commit is contained in:
parent
9a740d05aa
commit
e6313b54a4
@ -62,7 +62,7 @@ Usage: $prog [-z|--zero] [-a|--add] [-g|--clean-git] [-s|--set NUM] [-t|--test]
|
||||
Options:
|
||||
-z, --zero Set pkgrel to 0
|
||||
-a, --add Add 1 to current pkgrel
|
||||
-g, --clean-git Only operate on APKBUILDs with clean git status
|
||||
-g, --clean-git Only operate on APKBUILDs with clean git status (implies --add)
|
||||
-s, --set NUM Set pkgrel to NUM
|
||||
-t, --test Only verify that files have a valid pkgrel
|
||||
-f, --force Operate on files without a valid pkgrel
|
||||
@ -86,7 +86,10 @@ while true; do
|
||||
case $1 in
|
||||
-z|--zero) setto=0; cmd=do_set;;
|
||||
-a|--add) cmd=do_add;;
|
||||
-g|--clean-git) only_clean_git=1;;
|
||||
-g|--clean-git) # verify that we're in a git tree
|
||||
git rev-parse 2>/dev/null || die "not in a git tree"
|
||||
cmd=do_add
|
||||
only_clean_git=1;;
|
||||
-s|--set) setto=$2; shift; cmd=do_set;;
|
||||
-t|--test) cmd=do_nothing;;
|
||||
-f|--force) force=1;;
|
||||
|
Loading…
Reference in New Issue
Block a user