[X2Go-Commits] [maintenancescripts] 01/01: git/hooks/x2go-post-receive-tag-pending: switch to using an array for process invocations.

git-admin at x2go.org git-admin at x2go.org
Thu Jan 2 15:36:21 CET 2020


This is an automated email from the git hooks/post-receive script.

x2go pushed a commit to branch master
in repository maintenancescripts.

commit bda1ceaf6d60f6e57c33004b7a8d2ed6a0918e4a
Author: Mihai Moldovan <ionic at ionic.de>
Date:   Thu Jan 2 15:35:13 2020 +0100

    git/hooks/x2go-post-receive-tag-pending: switch to using an array for process invocations.
---
 git/hooks/x2go-post-receive-tag-pending | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/git/hooks/x2go-post-receive-tag-pending b/git/hooks/x2go-post-receive-tag-pending
index 0e44ecf..d796e2f 100755
--- a/git/hooks/x2go-post-receive-tag-pending
+++ b/git/hooks/x2go-post-receive-tag-pending
@@ -118,14 +118,15 @@ EOF
 }
 
 while read oldrev newrev refname; do
-  git_rev_list="git rev-list --reverse --stdin '${oldrev}..${newrev}'"
+  typeset -a git_rev_list
+  git_rev_list=( 'git' 'rev-list' '--reverse' '--stdin' "${oldrev}..${newrev}" )
   # For new branches/tags, do something special. Hopefully.
   typeset null_regex='^0{20,}$'
   if [[ "${oldrev}" =~ ${null_regex} ]]; then
-    git_rev_list="git rev-list --reverse --stdin '${newrev}' --not --branches='*' --tags='*'"
+    git_rev_list=( 'git' 'rev-list' '--reverse' '--stdin' "${newrev}" '--not' '--branches=*' '--tags=*' )
   fi
   git rev-parse --not --tags --not --branches='master' --branches='release/*' | grep -v "$(git rev-parse ${refname})" | \
-  ${git_rev_list} | \
+  ${git_rev_list[@]} | \
   while read rev; do
     d="${tempdir}/${rev}.diff"
     git show "${rev}" -- "debian/changelog" >"${d}"

--
Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/maintenancescripts.git


More information about the x2go-commits mailing list