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

contrib: svn-fixup-rename

From: Karl Chen <quarl_at_cs.berkeley.edu>
Date: 2005-09-17 02:39:33 CEST

Here's a client-side script for fixing renames.

I make this mistake all the time:
- Instead of "svn mv oldname newname", the user types "mv oldname
  newname".
- Even worse: the file might even be modified before or after the
  rename.
- Even worse: this may have happened for many files, e.g. "mv *.h
  include/".
    - svn (command-line) doesn't support a good way to do this
      anyway.

"svn-x-mv oldname newname" in this case fixes the problem for one
particular rename. It's a complete hack - there must be a
wc-level way to do this elegantly (please tell me how). This is
just a building block for the interesting one:

"svn-fixup-rename": heuristically matches up missing and new
files. It Does The Right Thing. Heuristics are based on file
contents and filename.

Does this sound useful to other people? I can polish this,
improve heuristics... svn-fixup-rename can even define a special
string to insert as a comment in the file, in effect emulating
Arch's solution to this problem (embedding metadata in the data).

-- 
Karl 2005-09-16 17:24
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Sep 17 02:40:20 2005

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.