s390-tools: update-crate.sh is buggy

Bug #2038560 reported by Simon Chopin
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
s390-tools (Ubuntu)
Triaged
Low
Unassigned

Bug Description

When trying to use debian/update-crate.sh to check that the vendor checking code actually works, said script failed when trying to deal with the patches.

This should be fixed in the next upload to devel, and could also probably be lumped into a bigger SRU in mantic.

The following changes fix it nicely:

diff -Nru s390-tools-2.29.0/debian/update-crate.sh s390-tools-2.29.0/debian/update-crate.sh
--- s390-tools-2.29.0/debian/update-crate.sh 2023-09-20 09:21:48.000000000 +0000
+++ s390-tools-2.29.0/debian/update-crate.sh 2023-10-05 09:21:48.000000000 +0000
@@ -1,6 +1,6 @@
 #!/bin/sh

-set -e
+set -ex

 newpackage=$1
 newversion=$2
@@ -8,11 +8,14 @@
 export QUILT_PATCHES=debian/patches

 # Pop vendor-remove-unused-deps.patch
-quilt pop vendor-remove-unused-deps.patch
+if quilt unapplied | grep -q vendor-remove-unused-deps.patch; then
+ quilt push -a
+ quilt pop debian/patches/vendor-remove-unused-deps.patch
+fi
 quilt pop

 # Prepare a new patch
-quilt new update-$newpackage-$newversion.patch
+quilt new debian/patches/update-$newpackage-$newversion.patch

 # Update the dependency in the lockfile
 quilt shell cargo update -p $newpackage --precise $newversion --manifest-path rust/pvsecret/Cargo.toml

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.