Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Heusel <christian@heusel.eu>2023-07-25 11:19:11 +0200
committerChristian Heusel <christian@heusel.eu>2023-11-20 15:00:21 +0100
commite7b82f36ef586127453e8c68660e0ef7826d0127 (patch)
tree844d2e08f360b87350f9854b1daf3773a063399f
parent4d7364ed1b893ba8498cf5a46b82413079b1131d (diff)
feat(build): add --updpkgsums option
This is useful so people who update patches etc. can update their checksums on building. The functionality itself was already implemented for --pkgver, but was not available separately. Fixes #168 Component: pkgctl build Signed-off-by: Christian Heusel <christian@heusel.eu>
-rw-r--r--contrib/completion/bash/devtools.in1
-rw-r--r--contrib/completion/zsh/_devtools.in1
-rw-r--r--doc/man/pkgctl-build.1.asciidoc3
-rw-r--r--src/lib/build/build.sh5
4 files changed, 10 insertions, 0 deletions
diff --git a/contrib/completion/bash/devtools.in b/contrib/completion/bash/devtools.in
index b28258f..e0fca51 100644
--- a/contrib/completion/bash/devtools.in
+++ b/contrib/completion/bash/devtools.in
@@ -173,6 +173,7 @@ _pkgctl_build_args=(
--pkgver
--pkgrel
--rebuild
+ --updpkgsums
-e --edit
-r --release
diff --git a/contrib/completion/zsh/_devtools.in b/contrib/completion/zsh/_devtools.in
index 49c4113..d3d6df0 100644
--- a/contrib/completion/zsh/_devtools.in
+++ b/contrib/completion/zsh/_devtools.in
@@ -47,6 +47,7 @@ _pkgctl_build_args=(
'--pkgver=[Set pkgver, reset pkgrel and update checksums]:pkgver:'
'--pkgrel=[Set pkgrel to a given value]:pkgrel:'
'--rebuild[Increment the pkgrel variable]'
+ '--updpkgsums[Regenerate the checksums]'
'(-e --edit)'{-e,--edit}'[Edit the PKGBUILD before building]'
'(-r --release)'{-r,--release}'[Automatically commit, tag and release after building]'
'(-m --message=)'{-m,--message=}"[Use the given <msg> as the commit message]:message:"
diff --git a/doc/man/pkgctl-build.1.asciidoc b/doc/man/pkgctl-build.1.asciidoc
index f68e7cf..2637ebc 100644
--- a/doc/man/pkgctl-build.1.asciidoc
+++ b/doc/man/pkgctl-build.1.asciidoc
@@ -59,6 +59,9 @@ PKGBUILD Options
*--rebuild*::
Increment the current pkgrel variable
+*--updpkgsums*::
+ Regenerate the checksums
+
*-e, --edit*::
Edit the PKGBUILD before building
diff --git a/src/lib/build/build.sh b/src/lib/build/build.sh
index 455f38a..8d58b63 100644
--- a/src/lib/build/build.sh
+++ b/src/lib/build/build.sh
@@ -55,6 +55,7 @@ pkgctl_build_usage() {
--pkgver=PKGVER Set pkgver, reset pkgrel and update checksums
--pkgrel=PKGREL Set pkgrel to a given value
--rebuild Increment the current pkgrel variable
+ --updpkgsums Regenerate the checksums
-e, --edit Edit the PKGBUILD before building
RELEASE OPTIONS
@@ -169,6 +170,10 @@ pkgctl_build() {
PKGREL="${1#*=}"
shift
;;
+ --updpkgsums)
+ UPDPKGSUMS=1
+ shift
+ ;;
--rebuild)
# shellcheck source=src/lib/util/git.sh
source "${_DEVTOOLS_LIBRARY_DIR}"/lib/util/git.sh