[packages/adapter: 122/631] - "ported" from zsh to bash ;) - make context (-urN) diffs (how could I forgot)

glen glen at pld-linux.org
Mon Sep 12 19:44:41 CEST 2016


commit 862ddf392f7536cf542278fe6d5f564a24638837
Author: jpc <jpc at pld-linux.org>
Date:   Thu May 13 22:18:42 2004 +0000

    - "ported" from zsh to bash ;)
    - make context (-urN) diffs (how could I forgot)
    
    Changed files:
        adapter.sh -> 1.2

 adapter.sh | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)
---
diff --git a/adapter.sh b/adapter.sh
index ccc18b7..8835101 100644
--- a/adapter.sh
+++ b/adapter.sh
@@ -1,4 +1,4 @@
-#!/bin/zsh
+#!/bin/bash
 
 if [[ $# -ne 1 || ! -f $1 ]]; then
   echo "Usage: $0 filename"
@@ -6,10 +6,12 @@ if [[ $# -ne 1 || ! -f $1 ]]; then
 fi
 
 ./adapter.awk "$1" > "$1.adapter"
-diff "$1" "$1.adapter"|less
+diff -urN "$1" "$1.adapter"|less
 echo -n "Are the changes OK? [yN] "
-read -q OK
-if [[ $OK == "y" ]]; then
+
+read -n 1 OK
+
+if [[ $OK == "y" || $OK == "Y" ]]; then
   mv "$1.adapter" "$1"
   cvs ci "$1"
 else
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/adapter.git/commitdiff/6ca0126d4d0c8c79feb7db10b0a0fade0f3b8885



More information about the pld-cvs-commit mailing list