Package not found: openSUSE:Slowroll:Build:2/python-bpython

File 0004-push-Do-not-remove-refresh-flag.patch of Package quilt

From 0d601b1987d2acee1b532ba19b8b518c571d9f35 Mon Sep 17 00:00:00 2001
From: Benjamin Poirier <bpoirier@suse.de>
Date: Fri, 31 Mar 2017 14:58:48 -0700
Subject: [PATCH 4/5] push: Do not remove refresh flag

This allows to preset it for a patch after it has been imported but before
it has been applied. The patch might apply without conflict but we'd still
like to "remind" the user to refresh it.
---
 quilt/delete.in |  1 +
 quilt/push.in   | 17 ++++++++++-------
 2 files changed, 11 insertions(+), 7 deletions(-)

Index: quilt-0.68/quilt/delete.in
===================================================================
--- quilt-0.68.orig/quilt/delete.in
+++ quilt-0.68/quilt/delete.in
@@ -133,6 +133,7 @@ then
 			exit 1
 		fi
 	fi
+	rm -f "$QUILT_PC/$patch~refresh"
 fi
 ### Local Variables:
 ### mode: shell-script
Index: quilt-0.68/quilt/push.in
===================================================================
--- quilt-0.68.orig/quilt/push.in
+++ quilt-0.68/quilt/push.in
@@ -190,12 +190,11 @@ add_patch()
 
 	if [ $status -eq 0 -o -n "$opt_force" ]
 	then
+		local refresh="$QUILT_PC/$patch~refresh"
 		add_to_db "$patch"
-		if [ $status -eq 0 ]
+		if [ $status -ne 0 ]
 		then
-			rm -f "$QUILT_PC/$patch~refresh"
-		else
-			touch "$QUILT_PC/$patch~refresh"
+			touch "$refresh"
 		fi
 
 		if [ -e "$QUILT_PC/$patch" ]
@@ -213,10 +212,14 @@ add_patch()
 		then
 			printf $"Patch %s appears to be empty; applied\n" \
 			       "$(print_patch "$patch")"
-		elif [ $status -ne 0 ]
+		elif [ -e "$refresh" ]
 		then
-			printf $"Applied patch %s (forced; needs refresh)\n" \
-			       "$(print_patch "$patch")"
+			local text
+			if [ "$opt_force" ]; then
+				text="forced; "
+			fi
+			printf $"Applied patch %s (%sneeds refresh)\n" \
+			       "$(print_patch "$patch")" "$text"
 		fi
 	else
 		rollback_patch "$patch"
openSUSE Build Service is sponsored by