[pacman-dev] [PATCH 4/4] pacdiff: Add option to overwrite, clarify remove option

Florian Pritz bluewind at xinu.at
Wed Dec 19 17:33:51 EST 2012


Signed-off-by: Florian Pritz <bluewind at xinu.at>
---
 contrib/pacdiff.sh.in | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/contrib/pacdiff.sh.in b/contrib/pacdiff.sh.in
index 97584b5..477a7ac 100644
--- a/contrib/pacdiff.sh.in
+++ b/contrib/pacdiff.sh.in
@@ -81,15 +81,16 @@ while IFS= read -u 3 -r -d '' pacfile; do
 		echo "  Files are identical, removing..."
 		rm -v "$pacfile"
 	else
-		echo -n "  File differences found. (V)iew, (S)kip, (R)emove: [v/s/r] "
+		echo -n "  (V)iew, (S)kip, (R)emove $file_type, (O)verwrite with $file_type: [v/s/r/o] "
 		while read c; do
 			case $c in
 				r|R) rm -v "$pacfile"; break ;;
+				o|O) mv -v "$pacfile" "$file"; break ;;
 				v|V)
 				$diffprog "$pacfile" "$file"
 				rm -iv "$pacfile"; break ;;
 				s|S) break ;;
-				*) echo -n "  Invalid answer. Try again: [v/s/r] "; continue ;;
+				*) echo -n "  Invalid answer. Try again: [v/s/r/o] "; continue ;;
 			esac
 		done
 	fi
-- 
1.8.0.2


More information about the pacman-dev mailing list