[Qa-jenkins-scm] [Git][qa/jenkins.debian.net][master] Take in a patch from dsa-nagios

Mattia Rizzolo gitlab at salsa.debian.org
Sun Dec 1 16:09:23 GMT 2019



Mattia Rizzolo pushed to branch master at Debian QA / jenkins.debian.net


Commits:
2528a65e by Mattia Rizzolo at 2019-12-01T16:09:03Z
Take in a patch from dsa-nagios

This is from this commit of the dsa-nagios.git.

commit d95cb3856c48aff6792f8a6799fb1f37d44c4c51
Author:     Peter Palfrader <peter at palfrader.org>
AuthorDate: Mon Oct 14 11:49:28 2019 +0200
Commit:     Peter Palfrader <peter at palfrader.org>
CommitDate: Mon Oct 14 11:49:28 2019 +0200

    dsa-check-running-kernel: sort kernel versions better

    When we ask apt-cache for information on the metapackage to extract the
    actual kernel image it depends on, we sort that output.  It's not clear
    why we do that, since we pass the option --no-all-versions to apt-cache
    so we should only get one answer anyhow.  Nevertheless, since we sort we
    might just as well use -V to version sort that output.  dpkg-version
    sort would be even better, but hey.  This is based on Erik Auerswald's
    patch in #884328.

Signed-off-by: Mattia Rizzolo <mattia at debian.org>

- - - - -


1 changed file:

- hosts/common/usr/local/bin/dsa-check-running-kernel


Changes:

=====================================
hosts/common/usr/local/bin/dsa-check-running-kernel
=====================================
@@ -94,7 +94,7 @@ get_avail() {
 
 	local imagename=0
 	# --no-all-versions show shows only the candidate
-	for vers in $(apt-cache --no-all-versions show ${prefix}-image-${metavers} | sed -n 's/^Depends: //p' | tr ',' '\n' | tr -d ' ' | grep ${prefix}-image | awk '{print $1}' | awk -F"|" '{print $1}' | sort -u); do
+	for vers in $(apt-cache --no-all-versions show ${prefix}-image-${metavers} | sed -n 's/^Depends: //p' | tr ',' '\n' | tr -d ' ' | grep ${prefix}-image | awk '{print $1}' | awk -F"|" '{print $1}' | sort -Vu); do
 		if dpkg --compare-versions "1.$vers" gt "1.$imagename"; then
 			imagename=$vers
 		fi



View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/commit/2528a65e9f463ff787842c557f00a6889d1e4a14

-- 
View it on GitLab: https://salsa.debian.org/qa/jenkins.debian.net/commit/2528a65e9f463ff787842c557f00a6889d1e4a14
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/qa-jenkins-scm/attachments/20191201/06a4244f/attachment-0001.html>


More information about the Qa-jenkins-scm mailing list