You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Alexis Huxley <ah...@gmx.net> on 2002/05/24 15:12:02 UTC

release stamping (not revision stamping) in the SVN world?

Hi Subversion People

On the list I saw someone mention this:

        svn cp -r 1000 /trunk /tags/foobar-1.0

as a way to tag releases.

And it raised a couple of questions for me, who's jumping
direct from RCS to SVN without passing through CVS.

At the moment (while SVN lacks module support) I have my various 
programs all stored directly under my SVN root like this:

        \__ prog1 __ src
        |        \__ lib
        \__ prog2 __ src
        |        \__ lib
        \__ prog3 __ src
                 \__ lib

So, should I rearrange my sources to be stored under /trunk like this, 
so that I can later make tags with the command line above?:

        \__ prog1 __ trunk __ src
        |        |        \__ lib
        |        \__ tags
        \__ prog2 __ trunk __ src
        |        |        \__ lib
        |        \__ tags
        \__ prog3 __ trunk __ src
        |        |        \__ lib
        |        \__ tags

Next, when I used to use RCS, I used a home-written script to take
the revision numbers of the files in a program, prompt the user
for a release number and then store *all* these numbers in a file
which was itself stored under RCS. The script would then take temporary 
copy of all the source files, and 'sed' its way through them, 
substituting "MARKER_RELEASE" for the release number. So that
when I compiled the program, and ran '<prog> --version' it new
what its release number was.

I am aware that I can put '$Header'-like strings in files stored under
SVN, but surely - at checkout time - those will be expanded to
something that doesn't comtain the "1.0" (or whatever) that I use
when tag the release with the "scn cp" command above? 

So, in the SVN world, how does one 'brand' ones sources with a 
release ID?

Many thanks!

Alexis
(At repository revision 37)

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

Re: release stamping (not revision stamping) in the SVN world?

Posted by Ben Collins-Sussman <su...@collab.net>.
Alexis Huxley <ah...@gmx.net> writes:

> So, should I rearrange my sources to be stored under /trunk like this, 
> so that I can later make tags with the command line above?:

As cmpilato already pointed out, you can index your repository by
branch, rather than by project.  It doesn't matter.  

Actually -- the important thing to remember here is that there *is* no
policy at all.  A tag is just a regular directory, created via "cheap
copy".  Organize your repository however you wish;  the distinction
between a tag, branch, and directory is only in your mind.  Hopefully
your repository structure will remind you how you want to think of
each.

> I am aware that I can put '$Header'-like strings in files stored under
> SVN, but surely - at checkout time - those will be expanded to
> something that doesn't comtain the "1.0" (or whatever) that I use
> when tag the release with the "scn cp" command above? 
> 
> So, in the SVN world, how does one 'brand' ones sources with a 
> release ID?

The $Revision$ keyword has nothing at all to do with the 'branding' of
your sources.  Take a look at how the Subversion project does it:  we
manually increment the software release numbers in our svn_version.h
header whenever we hit a new milestone.  If you want, you can make a
tag as well.

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

Re: release stamping (not revision stamping) in the SVN world?

Posted by cm...@collab.net.
Alexis Huxley <ah...@gmx.net> writes:

> Hi Subversion People
> 
> On the list I saw someone mention this:
> 
>         svn cp -r 1000 /trunk /tags/foobar-1.0
> 
> as a way to tag releases.
> 
> And it raised a couple of questions for me, who's jumping
> direct from RCS to SVN without passing through CVS.
> 
> At the moment (while SVN lacks module support) I have my various 
> programs all stored directly under my SVN root like this:
> 
>         \__ prog1 __ src
>         |        \__ lib
>         \__ prog2 __ src
>         |        \__ lib
>         \__ prog3 __ src
>                  \__ lib
> 
> So, should I rearrange my sources to be stored under /trunk like this, 
> so that I can later make tags with the command line above?:
> 
>         \__ prog1 __ trunk __ src
>         |        |        \__ lib
>         |        \__ tags
>         \__ prog2 __ trunk __ src
>         |        |        \__ lib
>         |        \__ tags
>         \__ prog3 __ trunk __ src
>         |        |        \__ lib
>         |        \__ tags

Well, you don't *have* to do so.  Instead of using the following
layout:

   /proj1
   /proj1/trunk
   /proj1/tags
   /proj2
   /proj2/trunk
   /proj2/tags
   /proj3
   /proj3/trunk
   /proj3/tags
  
You could do (if it makes life simpler for you):

   /trunk
   /trunk/proj1
   /trunk/proj2
   /trunk/proj3
   /tags
   /tags/proj1
   /tags/proj2
   /tags/proj3

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