You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Jamie Heilman <ja...@audible.transient.net> on 2004/06/07 20:25:37 UTC

need equiv. of cvs export -kv

Currently there seems to be no way to do an export from a svn repo and
have it automatically expand keywords such that an import of the code
at another site will not lose previous keyword information.
Eg. keyword "$Id: foo 127 2004-05-26 19:41:28Z jamie $" would be
exported as "foo 127 2004-05-26 19:41:28Z jamie"

I found a discussion of a similar feature request from December of
2002 in the dev list archives, and the outcome seemed to be "use a
script and do the substitution post-export" and while I don't have a
problem with that conceptually, its not quite as expediant as you
might imagine as you have to first check every file to see what
keyword properties it has set.  I'd like to request that an option to
the export command be added which automates the process.

-- 
Jamie Heilman                     http://audible.transient.net/~jamie/
"...thats the metaphorical equivalent of flopping your wedding tackle
 into a lion's mouth and flicking his lovespuds with a wet towel, pure
 insanity..."                                           -Rimmer

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: need equiv. of cvs export -kv

Posted by Greg Hudson <gh...@MIT.EDU>.
On Mon, 2004-06-07 at 19:18, Jamie Heilman wrote:
> kfogel@collab.net wrote:
> > Jamie Heilman <ja...@audible.transient.net> writes:
> > > Currently there seems to be no way to do an export from a svn repo and
> > > have it automatically expand keywords such that an import of the code
> > > at another site will not lose previous keyword information.

Incidentally, CVS never loses keyword information.  If you check out the
imported revisions with -ko, you'll see the original values.

(Subversion doesn't work the same way, although under normal
circumstances "svn import" doesn't set svn:keywords, so it doesn't lose
information either.  I don't know if svn import supports auto-props; if
it does, then presumably you lose information if you use auto-props to
set svn:keywords on some files.)


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: need equiv. of cvs export -kv

Posted by Jamie Heilman <ja...@audible.transient.net>.
kfogel@collab.net wrote:
> Jamie Heilman <ja...@audible.transient.net> writes:
> > Currently there seems to be no way to do an export from a svn repo and
> > have it automatically expand keywords such that an import of the code
> > at another site will not lose previous keyword information.
> > Eg. keyword "$Id: foo 127 2004-05-26 19:41:28Z jamie $" would be
> > exported as "foo 127 2004-05-26 19:41:28Z jamie"
> 
> Workaround: you could use the long forms of the keywords, which I
> believe CVS does not know about, and therefore would not expand.

I'm not sure how you came to the conclusion I was re-importing the
exported tree using CVS--you happen to be correct, but it didn't have
to be CVS, it could have been anything where there are keyword naming
"conflicts."  As it happens the trees I usually do exports of aren't
in my control so I can't choose which keywords to use.  I export them
so I can re-import on a vendor branch and keep track of upstream
changes in comparison to my fork.  If I were using svn or anything
else, I'd still want to be able to export the trees and preserve the
upstream keywords while using my own though.  Even if the keyword
syntax happened to collide between the version control software.

-- 
Jamie Heilman                     http://audible.transient.net/~jamie/

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: need equiv. of cvs export -kv

Posted by kf...@collab.net.
Jamie Heilman <ja...@audible.transient.net> writes:
> Currently there seems to be no way to do an export from a svn repo and
> have it automatically expand keywords such that an import of the code
> at another site will not lose previous keyword information.
> Eg. keyword "$Id: foo 127 2004-05-26 19:41:28Z jamie $" would be
> exported as "foo 127 2004-05-26 19:41:28Z jamie"

Workaround: you could use the long forms of the keywords, which I
believe CVS does not know about, and therefore would not expand.

-Karl

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: need equiv. of cvs export -kv

Posted by "Øyvind A. Holm" <su...@sunbase.org>.
On 2004-06-07 13:25-0700 Jamie Heilman wrote:

> Currently there seems to be no way to do an export from a svn repo and
> have it automatically expand keywords such that an import of the code
> at another site will not lose previous keyword information.
> Eg. keyword "$Id: foo 127 2004-05-26 19:41:28Z jamie $" would be
> exported as "foo 127 2004-05-26 19:41:28Z jamie"

I would like a feature like this myself, so in the meantime I'm using a
small script that replaces $Id$ and $Date$ the way you describe above
when I export files from the repository. You can find it on

http://svnutils.tigris.org/nonav/source/browse/*checkout*/svnutils/trunk/src/strip_id
or
http://svn.sunbase.org/repos/svnutils/trunk/src/strip_id

Regards,
Øyvind A. Holm
---------------------
cat /dev/urandom >SCO