[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: clear out insane shortnames (was: svn commit: r899499)

From: Greg Stein <gstein_at_gmail.com>
Date: Mon, 23 May 2011 17:24:53 -0400

On Mon, May 23, 2011 at 17:06, Stefan Sperling <stsp_at_elego.de> wrote:
>...
> I still prefer typing --ri over --reintegrate, or --ie over
> --ignore-externals. Maybe we should allow creating custom short aliases
> for such options from the client config file?
> (I know you hate config knobs, too, but I want short options one way
> or another.)

Yeah... config knobs are almost worse than these :-P

If you want these short options, below is a patch that I could
commit... hehehe....

Index: stsp-svn.py
===================================================================
--- stsp-svn.py (revision 0)
+++ stsp-svn.py (working copy)
@@ -0,0 +1,39 @@
+#!/usr/bin/env python
+
+import sys
+import os
+
+ARG_MAP = {
+ "--sd": "--set-depth",
+ "--enc": "--encoding",
+ "--soc": "--stop-on-copy",
+ "--nac": "--no-auth-cache",
+ "--dry": "--dry-run",
+ "--ndd": "--no-diff-deleted",
+ "--na": "--notice-ancestry",
+ "--ia": "--ignore-ancestry",
+ "--ie": "--ignore-externals",
+ "--rd": "--reverse-diff",
+ "--ro": "--record-only",
+ "--cd": "--config-dir",
+ "--cl": "--changelist",
+ "--kl": "--keep-local",
+ "--sr": "--show-revs",
+ "--ri": "--reintegrate",
+ "--sca": "--show-copies-as-adds",
+ "--ik": "--ignore-keywords",
+ "--iw": "--ignore-whitespace",
+ "--idiff": "--internal-diff",
+ "--keep-locks": "--no-unlock",
+ "--keep-cl": "--keep-changelists",
+ }
+
+args = []
+
+for arg in sys.argv:
+ if arg in ARG_MAP:
+ args.append(ARG_MAP[arg])
+ else:
+ args.append(arg)
+
+os.execvp("svn", args)

Property changes on: stsp-svn.py
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
Received on 2011-05-23 23:25:20 CEST

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.