[or-cvs] r13519: Rename patch-vidalia-language.sh Don't keep backups of patch (torbrowser/trunk/build-scripts)

sjm217 at seul.org sjm217 at seul.org
Thu Feb 14 22:31:05 UTC 2008


Author: sjm217
Date: 2008-02-14 17:31:05 -0500 (Thu, 14 Feb 2008)
New Revision: 13519

Added:
   torbrowser/trunk/build-scripts/patch-vidalia-language.sh
Removed:
   torbrowser/trunk/build-scripts/patch-language.sh
Modified:
   torbrowser/trunk/build-scripts/Makefile
   torbrowser/trunk/build-scripts/patch-firefox-language.sh
Log:
Rename patch-vidalia-language.sh
Don't keep backups of patched files

Modified: torbrowser/trunk/build-scripts/Makefile
===================================================================
--- torbrowser/trunk/build-scripts/Makefile	2008-02-14 22:24:48 UTC (rev 13518)
+++ torbrowser/trunk/build-scripts/Makefile	2008-02-14 22:31:05 UTC (rev 13519)
@@ -190,7 +190,7 @@
 ## Set the language for Vidalia
 patch-vidalia-language:
 	## Patch Vidalia
-	./patch-language.sh $(BUNDLE)/Data/Vidalia/vidalia.conf $(LANGCODE)
+	./patch-vidalia-language.sh $(BUNDLE)/Data/Vidalia/vidalia.conf $(LANGCODE)
 
 patch-firefox-language:
 	## Patch Firefox prefs.js

Modified: torbrowser/trunk/build-scripts/patch-firefox-language.sh
===================================================================
--- torbrowser/trunk/build-scripts/patch-firefox-language.sh	2008-02-14 22:24:48 UTC (rev 13518)
+++ torbrowser/trunk/build-scripts/patch-firefox-language.sh	2008-02-14 22:31:05 UTC (rev 13519)
@@ -19,3 +19,6 @@
 
 ## Replace LanguageCode value with $LANGCODE
 sed -c "s/BUNDLELOCALE/$LANGCODE/" "$ORIGFILENAME" > "$FILENAME"
+
+## Remove backup
+rm -f "$ORIGFILENAME"
\ No newline at end of file

Deleted: torbrowser/trunk/build-scripts/patch-language.sh
===================================================================
--- torbrowser/trunk/build-scripts/patch-language.sh	2008-02-14 22:24:48 UTC (rev 13518)
+++ torbrowser/trunk/build-scripts/patch-language.sh	2008-02-14 22:31:05 UTC (rev 13519)
@@ -1,35 +0,0 @@
-#!/bin/sh
-
-###
-### Set language code in Vidalia config file
-###
-### Copyright 2007 Steven J. Murdoch <http://www.cl.cam.ac.uk/users/sjm217/>
-### See LICENSE for licensing information
-###
-### $Id$
-###
-
-## Parse command line
-FILENAME=$1
-MOZLANG=$2
-
-## Handle exceptions where Mozilla language definition doesn't equal Vidalia's
-case "$MOZLANG" in
-    'es-ES') LANGCODE='es'
-    ;;
-    'fa-IR') LANGCODE='fa'
-    ;;
-    'pt-PT') LANGCODE='pt'
-    ;;
-    'zh-CN') LANGCODE='zh-cn'
-    ;;
-    *) LANGCODE="$MOZLANG"
-    ;;
-esac
-
-## Backup original file
-ORIGFILENAME=$FILENAME.orig
-mv "$FILENAME" "$ORIGFILENAME"
-
-## Replace LanguageCode value with $LANGCODE
-sed -c "s/\\(LanguageCode=\\).*/\\1$LANGCODE/" "$ORIGFILENAME" > "$FILENAME"

Copied: torbrowser/trunk/build-scripts/patch-vidalia-language.sh (from rev 13517, torbrowser/trunk/build-scripts/patch-language.sh)
===================================================================
--- torbrowser/trunk/build-scripts/patch-vidalia-language.sh	                        (rev 0)
+++ torbrowser/trunk/build-scripts/patch-vidalia-language.sh	2008-02-14 22:31:05 UTC (rev 13519)
@@ -0,0 +1,38 @@
+#!/bin/sh
+
+###
+### Set language code in Vidalia config file
+###
+### Copyright 2007 Steven J. Murdoch <http://www.cl.cam.ac.uk/users/sjm217/>
+### See LICENSE for licensing information
+###
+### $Id$
+###
+
+## Parse command line
+FILENAME=$1
+MOZLANG=$2
+
+## Handle exceptions where Mozilla language definition doesn't equal Vidalia's
+case "$MOZLANG" in
+    'es-ES') LANGCODE='es'
+    ;;
+    'fa-IR') LANGCODE='fa'
+    ;;
+    'pt-PT') LANGCODE='pt'
+    ;;
+    'zh-CN') LANGCODE='zh-cn'
+    ;;
+    *) LANGCODE="$MOZLANG"
+    ;;
+esac
+
+## Backup original file
+ORIGFILENAME=$FILENAME.orig
+mv "$FILENAME" "$ORIGFILENAME"
+
+## Replace LanguageCode value with $LANGCODE
+sed -c "s/\\(LanguageCode=\\).*/\\1$LANGCODE/" "$ORIGFILENAME" > "$FILENAME"
+
+## Remove backup
+rm -f "$ORIGFILENAME"



More information about the tor-commits mailing list