Kill trailing spaces
authorThomas Arendsen Hein <thomas@intevation.de>
Thu, 21 Jun 2007 09:25:49 +0200
changeset 4659 7a7d4937272baf90af6f00bc47807a9172279583
parent 4658 17f5d2069551ee62d2b0616ce3451a5f84e746f1
child 4660 cfa477946181824f4c769580ebf59710090ba08a
child 4672 272c0a09b2032046de3671eada475e1eace2b772
push id1
push usergszorc@mozilla.com
push dateWed, 18 Mar 2015 16:34:57 +0000
Kill trailing spaces
hgeditor
mercurial/commands.py
mercurial/patch.py
templates/gitweb/map
templates/static/style.css
tests/printenv.py
tests/test-annotate
tests/test-dispatch
tests/test-empty-file
tests/test-empty-group
tests/test-hgrc
tests/test-hook
tests/test-issue322
tests/test-issue433
tests/test-mq-qrefresh-replace-log-message
tests/test-rename-merge2
tests/test-tags
tests/test-up-local-change
--- a/hgeditor
+++ b/hgeditor
@@ -37,17 +37,17 @@ HGTMP="${TMPDIR-/tmp}/hgeditor.$RANDOM.$
     grep '^HG: changed' "$1" | cut -b 13- | while read changed; do
         hg diff "$changed" >> "$HGTMP/diff"
     done
 )
 
 cat "$1" > "$HGTMP/msg"
 
 MD5=$(which md5sum 2>/dev/null) || \
-    MD5=$(which md5 2>/dev/null) 
+    MD5=$(which md5 2>/dev/null)
 [ -x "${MD5}" ] && CHECKSUM=`${MD5} "$HGTMP/msg"`
 if [ -s "$HGTMP/diff" ]; then
     $EDITOR "$HGTMP/msg" "$HGTMP/diff" || exit $?
 else
     $EDITOR "$HGTMP/msg" || exit $?
 fi
 [ -x "${MD5}" ] && (echo "$CHECKSUM" | ${MD5} -c >/dev/null 2>&1 && exit 13)
 
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -2510,17 +2510,17 @@ def tag(ui, repo, name, rev_=None, **opt
         if opts['rev']:
             raise util.Abort(_("use only one form to specify the revision"))
     if opts['rev'] and opts['remove']:
         raise util.Abort(_("--rev and --remove are incompatible"))
     if opts['rev']:
         rev_ = opts['rev']
     message = opts['message']
     if opts['remove']:
-        if not name in repo.tags(): 
+        if not name in repo.tags():
             raise util.Abort(_('tag %s does not exist') % name)
         rev_ = nullid
         if not message:
             message = _('Removed tag %s') % name
     elif name in repo.tags() and not opts['force']:
         raise util.Abort(_('a tag named %s already exists (use -f to force)')
                          % name)
     if not rev_ and repo.dirstate.parents()[1] != nullid:
--- a/mercurial/patch.py
+++ b/mercurial/patch.py
@@ -298,17 +298,17 @@ def patch(patchname, ui, strip=1, cwd=No
 
         args = []
         patcher = ui.config('ui', 'patch')
         if not patcher:
             patcher = util.find_exe('gpatch') or util.find_exe('patch')
             # Try to be smart only if patch call was not supplied
             if util.needbinarypatch():
                 args.append('--binary')
-                
+
         if not patcher:
             raise util.Abort(_('no patch command found in hgrc or PATH'))
 
         if cwd:
             args.append('-d %s' % util.shellquote(cwd))
         fp = os.popen('%s %s -p%d < %s' % (patcher, ' '.join(args), strip,
                                            util.shellquote(patchname)))
 
--- a/templates/gitweb/map
+++ b/templates/gitweb/map
@@ -46,12 +46,12 @@ filelogparent = '<tr><td align="right">p
 filediffchild = '<tr><td>child {rev}</td><td style="font-family:monospace"><a class="list" href="{url}diff/{node|short}/{file|urlescape}{sessionvars%urlparameter}">{node|short}</a></td></tr>'
 filelogchild = '<tr><td align="right">child #rev#:&nbsp;</td><td><a href="{url}file{node|short}/#file|urlescape#{sessionvars%urlparameter}">#node|short#</a></td></tr>'
 shortlog = shortlog.tmpl
 tagtag = '<span class="tagtag" title="{name}">{name}</span> '
 branchtag = '<span class="branchtag" title="{name}">{name}</span> '
 shortlogentry = '<tr class="parity#parity#"><td class="age"><i>#date|age# ago</i></td><td><i>#author#</i></td><td><a class="list" href="{url}rev/#node|short#{sessionvars%urlparameter}"><b>#desc|strip|firstline|escape#</b> <span class="logtags">{branches%branchtag}{tags%tagtag}</span></a></td><td class="link" nowrap><a href="{url}rev/#node|short#{sessionvars%urlparameter}">changeset</a> | <a href="{url}file/#node|short#{sessionvars%urlparameter}">manifest</a></td></tr>'
 filelogentry = '<tr class="parity#parity#"><td class="age"><i>#date|age# ago</i></td><td><a class="list" href="{url}rev/#node|short#{sessionvars%urlparameter}"><b>#desc|strip|firstline|escape#</b></a></td><td class="link"><a href="{url}file/#node|short#/#file|urlescape#{sessionvars%urlparameter}">file</a>&nbsp;|&nbsp;<a href="{url}diff/#node|short#/#file|urlescape#{sessionvars%urlparameter}">diff</a>&nbsp;|&nbsp;<a href="{url}annotate/#node|short#/#file|urlescape#{sessionvars%urlparameter}">annotate</a> #rename%filelogrename#</td></tr>'
 archiveentry = ' | <a href="{url}archive/{node|short}{extension}">#type|escape#</a> '
-indexentry = '<tr class="parity#parity#"><td><a class="list" href="#url#{sessionvars%urlparameter}"><b>#name|escape#</b></a></td><td>#description#</td><td>#contact|obfuscate#</td><td class="age">#lastchange|age# ago</td><td class="indexlinks"><a class="rss_logo" href="#url#rss-log">RSS</a> #archives%archiveentry#</td></tr>' 
+indexentry = '<tr class="parity#parity#"><td><a class="list" href="#url#{sessionvars%urlparameter}"><b>#name|escape#</b></a></td><td>#description#</td><td>#contact|obfuscate#</td><td class="age">#lastchange|age# ago</td><td class="indexlinks"><a class="rss_logo" href="#url#rss-log">RSS</a> #archives%archiveentry#</td></tr>'
 index = index.tmpl
 urlparameter = '#separator##name#=#value|urlescape#'
 hiddenformentry = '<input type="hidden" name="#name#" value="#value|escape#" />'
--- a/templates/static/style.css
+++ b/templates/static/style.css
@@ -1,14 +1,14 @@
 a { text-decoration:none; }
 .age { white-space:nowrap; }
 .indexlinks { white-space:nowrap; }
 .parity0 { background-color: #dddddd; }
 .parity1 { background-color: #eeeeee; }
-.lineno { width: 60px; color: #aaaaaa; font-size: smaller; 
+.lineno { width: 60px; color: #aaaaaa; font-size: smaller;
           text-align: right; padding-right:1em; }
 .plusline { color: green; }
 .minusline { color: red; }
 .atline { color: purple; }
 .annotate { font-size: smaller; text-align: right; padding-right: 1em; }
 .buttons a {
   background-color: #666666;
   padding: 2pt;
@@ -41,17 +41,17 @@ pre { margin: 0; }
   color: white;
   float: right;
   clear: right;
   text-align: left;
 }
 
 .logo a {
   font-weight: bold;
-  font-size: 150%; 
+  font-size: 150%;
   color: #999;
 }
 
 /* Changelog/Filelog entries */
 .logEntry { width: 100%; }
 .logEntry .age { width: 15%; }
 .logEntry th { font-weight: normal; text-align: right; vertical-align: top; }
 .logEntry th.age, .logEntry th.firstline { font-weight: bold; }
--- a/tests/printenv.py
+++ b/tests/printenv.py
@@ -22,17 +22,17 @@ out = sys.stdout
 name = sys.argv[1]
 if len(sys.argv) > 2:
     exitcode = int(sys.argv[2])
     if len(sys.argv) > 3:
         out = open(sys.argv[3], "ab")
 
 # variables with empty values may not exist on all platforms, filter
 # them now for portability sake.
-env = [k for k,v in os.environ.iteritems() 
+env = [k for k, v in os.environ.iteritems()
        if k.startswith("HG_") and v]
 env.sort()
 
 # edit the variable part of the variable
 url = os.environ.get("HG_URL", "")
 if url.startswith("file:"):
     os.environ["HG_URL"] = "file:"
 elif url.startswith("remote:http"):
--- a/tests/test-annotate
+++ b/tests/test-annotate
@@ -73,17 +73,17 @@ echo d >> b
 hg ci -mmerge2 -d '4 0'
 echo % annotate after rename merge
 hg annotate -nf b
 
 echo % linkrev vs rev
 hg annotate -r tip a
 
 # test issue 589
-# annotate was crashing when trying to --follow something 
+# annotate was crashing when trying to --follow something
 # like A -> B -> A
 echo % generate ABA rename configuration
 echo foo > foo
 hg add foo
 hg ci -m addfoo
 hg rename foo bar
 hg ci -m renamefoo
 hg rename bar foo
--- a/tests/test-dispatch
+++ b/tests/test-dispatch
@@ -17,9 +17,9 @@ cat = -v
 EOF
 hg cat a
 
 echo '% no repo'
 cd ..
 hg cat
 
 exit 0
- 
\ No newline at end of file
+
--- a/tests/test-empty-file
+++ b/tests/test-empty-file
@@ -13,13 +13,13 @@ hg commit -m 'add empty2' -d '1000000 0'
 hg up -C 0
 touch empty3
 hg add empty3
 hg commit -m 'add empty3' -d '1000000 0'
 
 hg heads
 
 hg merge 1
-# before changeset 05257fd28591, we didn't notice the 
+# before changeset 05257fd28591, we didn't notice the
 # empty file that came from rev 1.
 hg status
 hg commit -m merge -d '1000000 0'
 hg manifest --debug tip
--- a/tests/test-empty-group
+++ b/tests/test-empty-group
@@ -1,17 +1,17 @@
 #!/bin/sh
 #
-#  A          B    
-#  
-#  3  4       3    
-#  |\/|       |\   
-#  |/\|       | \  
-#  1  2       1  2 
-#  \ /        \ /  
+#  A          B
+#
+#  3  4       3
+#  |\/|       |\
+#  |/\|       | \
+#  1  2       1  2
+#  \ /        \ /
 #   0          0
 #
 # if the result of the merge of 1 and 2
 # is the same in 3 and 4, no new manifest
 # will be created and the manifest group
 # will be empty during the pull
 #
 # (plus we test a failure where outgoing
--- a/tests/test-hgrc
+++ b/tests/test-hgrc
@@ -1,7 +1,7 @@
 #!/bin/sh
 
 mkdir t
 cd t
 hg init
 echo "invalid" > .hg/hgrc
-hg status 2>&1 |sed -e "s:/.*\(/t/.*\):...\1:" 
+hg status 2>&1 |sed -e "s:/.*\(/t/.*\):...\1:"
--- a/tests/test-hook
+++ b/tests/test-hook
@@ -35,17 +35,17 @@ hg update -C 0
 echo b > b
 hg add b
 hg commit -m b -d '1 0'
 hg merge 1
 hg commit -m merge -d '2 0'
 
 # test generic hooks
 hg id
-hg cat b 
+hg cat b
 
 cd ../b
 hg pull ../a
 
 # tag hooks can see env vars
 cd ../a
 echo 'pretag = python ../printenv.py pretag' >> .hg/hgrc
 echo 'tag = unset HG_PARENT1 HG_PARENT2; python ../printenv.py tag' >> .hg/hgrc
--- a/tests/test-issue322
+++ b/tests/test-issue322
@@ -1,25 +1,25 @@
 #!/bin/sh
 # http://www.selenic.com/mercurial/bts/issue322
 
 echo % file replaced with directory
 
 hg init a
-cd a       
-echo a > a 
-hg commit -Ama 
-rm a       
-mkdir a    
+cd a
+echo a > a
+hg commit -Ama
+rm a
+mkdir a
 echo a > a/a
 
 echo % should fail - would corrupt dirstate
 hg add a/a
 
-cd ..      
+cd ..
 
 echo % directory replaced with file
 
 hg init c
 cd c
 mkdir a
 echo a > a/a
 hg commit -Ama
--- a/tests/test-issue433
+++ b/tests/test-issue433
@@ -1,10 +1,10 @@
 #!/bin/sh
 # http://www.selenic.com/mercurial/bts/issue433
 
 hg init a
-cd a       
-echo a > a 
-hg commit -Ama 
+cd a
+echo a > a
+hg commit -Ama
 
 hg parents -r 0 doesnotexist
 true
--- a/tests/test-mq-qrefresh-replace-log-message
+++ b/tests/test-mq-qrefresh-replace-log-message
@@ -14,17 +14,17 @@ hg add file
 hg qrefresh
 echo =======================
 echo "Should display 'First commit message'"
 hg log -l1 -v | sed -n '/description/,$p'
 echo
 
 # Testing changing message with -m
 echo bbbb > file
-hg qrefresh -m "Second commit message" 
+hg qrefresh -m "Second commit message"
 echo =======================
 echo "Should display 'Second commit message'"
 hg log -l1 -v | sed -n '/description/,$p'
 echo
 
 
 # Testing changing message with -l
 echo "Third commit message" > logfile
@@ -36,15 +36,15 @@ printf "Should display 'Third commit mes
 hg log -l1 -v | sed -n '/description/,$p'
 echo
 
 # Testing changing message with -l-
 hg qnew -m "First commit message" second-patch
 echo aaaa > file2
 hg add file2
 echo bbbb > file2
-(echo "Fifth commit message" 
+(echo "Fifth commit message"
 echo " This is the 5th log message" >> logfile) |\
 hg qrefresh -l-
 echo =======================
 printf "Should display 'Fifth commit message\\\n This is the 5th log message'\n"
 hg log -l1 -v | sed -n '/description/,$p'
 echo
--- a/tests/test-rename-merge2
+++ b/tests/test-rename-merge2
@@ -7,17 +7,17 @@ cat <<EOF > merge
 import sys, os
 f = open(sys.argv[1], "wb")
 f.write("merge %s %s %s" % (sys.argv[1], sys.argv[2], sys.argv[3]))
 f.close()
 EOF
 HGMERGE="python ../merge"; export HGMERGE
 
 # perform a test merge with possible renaming
-# 
+#
 # args:
 # $1 = action in local branch
 # $2 = action in remote branch
 # $3 = action in working dir
 # $4 = expected result
 tm()
 {
     mkdir t
@@ -52,28 +52,28 @@ tm()
     echo "test L:$1 R:$2 W:$3 - $4"
     echo "--------------"
     hg merge -y --debug --traceback
 
     echo "--------------"
     hg status -camC -X rev
 
     hg ci -m "merge" -d "0 0"
-    
+
     echo "--------------"
     echo
 
     cd ..
     rm -r t
 }
 
-up() { 
+up() {
     cp rev $1
     hg add $1 2> /dev/null
-    if [ "$2" != "" ] ; then 
+    if [ "$2" != "" ] ; then
 	cp rev $2
 	hg add $2 2> /dev/null
     fi
 }
 
 uc() { up $1; hg cp $1 $2; } # update + copy
 um() { up $1; hg mv $1 $2; }
 nc() { hg cp $1 $2; } # just copy
@@ -90,15 +90,15 @@ tm "nm a b" "      " "      " "8  nothin
 tm "um a b" "um a b" "      " "9  do merge with ancestor in a"
 #tm "um a c" "um x c" "      " "10 do merge with no ancestor"
 tm "nm a b" "nm a c" "      " "11 get c, keep b"
 tm "nc a b" "up b  " "      " "12 merge b no ancestor"
 tm "up b  " "nm a b" "      " "13 merge b no ancestor"
 tm "nc a b" "up a b" "      " "14 merge b no ancestor"
 tm "up b  " "nm a b" "      " "15 merge b no ancestor, remove a"
 tm "nc a b" "up a b" "      " "16 get a, merge b no ancestor"
-tm "up a b" "nc a b" "      " "17 keep a, merge b no ancestor" 
+tm "up a b" "nc a b" "      " "17 keep a, merge b no ancestor"
 tm "nm a b" "up a b" "      " "18 merge b no ancestor"
 tm "up a b" "nm a b" "      " "19 merge b no ancestor, prompt remove a"
 tm "up a  " "um a b" "      " "20 merge a and b to b, remove a"
 tm "um a b" "up a  " "      " "21 merge a and b to b"
 #tm "nm a b" "um x a" "      " "22 get a, keep b"
 tm "nm a b" "up a c" "      " "23 get c, keep b"
--- a/tests/test-tags
+++ b/tests/test-tags
@@ -76,17 +76,17 @@ hg ci -m 'change foo 1' -d '1000000 0' #
 hg up -C 1
 hg tag -r 1 -d '1000000 0' -f bar      # rev 3
 hg up -C 1
 echo >> foo
 hg ci -m 'change foo 2' -d '1000000 0' # rev 4
 hg tags
 
 # test tag removal
-hg tag --remove -d '1000000 0' bar 
+hg tag --remove -d '1000000 0' bar
 hg tip
 hg tags
 
 echo '% remove nonexistent tag'
 hg tag --remove -d '1000000 0' foobar
 hg tip
 
 # test tag rank
--- a/tests/test-up-local-change
+++ b/tests/test-up-local-change
@@ -58,11 +58,11 @@ hg diff --nodates
 # test a local add
 cd ..
 hg init a
 hg init b
 echo a > a/a
 echo a > b/a
 hg --cwd a commit -A -m a
 cd b
-hg add a 
+hg add a
 hg pull -u ../a
 hg st