Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/src/pkgctl.in
diff options
context:
space:
mode:
Diffstat (limited to 'src/pkgctl.in')
-rw-r--r--src/pkgctl.in20
1 files changed, 16 insertions, 4 deletions
diff --git a/src/pkgctl.in b/src/pkgctl.in
index 070e0cd..9deb4b2 100644
--- a/src/pkgctl.in
+++ b/src/pkgctl.in
@@ -27,7 +27,7 @@ usage() {
release Release step to commit, tag and upload build artifacts
repo Manage Git packaging repositories and their configuration
search Search for an expression across the GitLab packaging group
- version Show pkgctl version information
+ version Package version related commands
OPTIONS
-h, --help Show this help text
@@ -39,6 +39,12 @@ if (( $# < 1 )); then
exit 1
fi
+pkgctl_version_print() {
+ cat <<- _EOF_
+ pkgctl @buildtoolver@
+_EOF_
+}
+
export _DEVTOOLS_COMMAND='pkgctl'
setup_workdir
@@ -114,14 +120,20 @@ while (( $# )); do
pkgctl_search "$@"
exit 0
;;
- version|--version|-V)
+ version)
_DEVTOOLS_COMMAND+=" $1"
shift
- # shellcheck source=src/lib/version/version.sh
- source "${_DEVTOOLS_LIBRARY_DIR}"/lib/version/version.sh
+ # shellcheck source=src/lib/version.sh
+ source "${_DEVTOOLS_LIBRARY_DIR}"/lib/version.sh
pkgctl_version "$@"
exit 0
;;
+ --version|-V)
+ _DEVTOOLS_COMMAND+=" $1"
+ shift
+ pkgctl_version_print
+ exit 0
+ ;;
*)
die "invalid command: %s" "$1"
;;