[DRE-commits] [pkg-ruby-extras] 01/01: build-and-upload: fix check for security upload

Antonio Terceiro terceiro at moszumanska.debian.org
Mon Dec 12 13:14:53 UTC 2016


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

terceiro pushed a commit to branch master
in repository pkg-ruby-extras.

commit a3d052e9a69d15586963d7d158117df9883614f9
Author: Antonio Terceiro <terceiro at debian.org>
Date:   Mon Dec 12 11:13:59 2016 -0200

    build-and-upload: fix check for security upload
    
    Not all uploads that mention a CVE need urgency high
---
 build-and-upload | 18 +++++++++---------
 1 file changed, 9 insertions(+), 9 deletions(-)

diff --git a/build-and-upload b/build-and-upload
index 6112822..a57f549 100755
--- a/build-and-upload
+++ b/build-and-upload
@@ -249,6 +249,14 @@ ask_to_proceed() {
   fi
 }
 
+check_security_upload() {
+  urgency=$(dpkg-parsechangelog -SUrgency)
+  if [ "$urgency" != 'high' ]; then
+    echo "Security upload should have urgency=high"
+    exit 1
+  fi
+}
+
 source=$(dpkg-parsechangelog -SSource)
 version=$(dpkg-parsechangelog -SVersion | sed -e 's/^[0-9]\+://') # remove epoch
 arch=$(dpkg --print-architecture)
@@ -263,6 +271,7 @@ case "$distribution" in
       git_builder="$git_builder"\ --force-orig-source
     fi
     host=security-master
+    check_security_upload
     ;;
   experimental)
     git_builder="$git_builder"\ -c\ unstable-${arch}-sbuild
@@ -275,15 +284,6 @@ case "$distribution" in
     true
 esac
 
-# check urgency for security upload
-if [ "$host" = 'security-master' ] || dpkg-parsechangelog | grep -q CVE; then
-  urgency=$(dpkg-parsechangelog -SUrgency)
-  if [ "$urgency" != 'high' ] && [ "$distribution" != "unstable" ] && [ "$distribution" != 'UNRELEASED' ]; then
-    echo "Security upload should have urgency=high"
-    exit 1
-  fi
-fi
-
 gbp_buildpackage=gbp\ buildpackage\ --git-ignore-branch\ --git-export-dir=../build-area
 
 # build

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ruby-extras/pkg-ruby-extras.git



More information about the Pkg-ruby-extras-commits mailing list