Results 1 to 12 of 12

Thread: labelling in subversion

  1. #1

    labelling in subversion

    Hi guys,

    I have one directory content some files and directories.

    And I want to label from the main directory recursive to the end of the lower level files by putting revision from subversion.

    Can I do that by any chance or should I put the label manually ?

    Can you guys show me how ?

    Thanks,

  2. #2
    Subversion has no concept of "labels". Just files and directories.

    If you want a convenient "name" for the state of all the files at one point in time, you're really looking at a tag, which in Subversion is really just a copy which you've given special meaning to. See http://svnbook.red-bean.com/nightly/...erge.tags.html

  3. #3
    Hi,

    But I read in documentation, there is a function called svn propset which similar as labelling and they have auto version as well, which I like it.

    Can I do like this :
    svn propset svn:autoversioned file:///path/

    Am I right or Any idea what property for ?

  4. #4
    svn:autoversioned is not a property that a user should manipulate. Per the documentation, this is set automatically if the file was manipulated via Autoversioning over WebDAV. It does not change the behavior of Subversion, it's merely informational.

    Also, svn:autoversioned is a revision property, so you can't set it without the --revprop switch.

    Please read the section of the manual on properties. http://svnbook.red-bean.com/nightly/...ced.props.html

  5. #5
    Hi andyl,

    So what's the best way for me to put the version/label in my directory in subversion ? like in source safe, if you're familiar.

    I don't think tag is good enough because it's just copy files to directory which has the revision name.

    But I want something to be store inside which I think like property.

    I have tried this :
    Code:
    $  svn propset svn:autoversioned -r11 --revprop first/
    svn: Repository has not been enabled to accept revision propchanges;
    ask the administrator to create a pre-revprop-change hook
    Can you give the right exact command using propset or propedit please ? using autoversioning or manual version ?

  6. #6
    Again, Subversion has no concept like VSS's label.

    Are you discarding tags purely because they're copies? Keep in mind that copies in Subversion are cheap and take up no space in the repository.

    You're using propset properly. Read the error message again. You need to enable the revprop hook script on the repository itself.

    Have you read the manual's relevant sections? http://svnbook.org/

  7. #7
    Senior Member
    Join Date
    Jan 2005
    Location
    Würselen - Germany
    Posts
    1,148
    Hi,

    Quote Originally Posted by andyl
    ...and take up no space in the repository.
    i have to make a note on that. That's not 100% true, cause it needs space in the repository but very little space. I have checked this and it's about 1 kb per tag.

    Kind regards.
    Karl Heinz Marbaise

  8. #8
    Quote Originally Posted by kama
    Hi,

    Quote Originally Posted by andyl
    ...and take up no space in the repository.
    i have to make a note on that. That's not 100% true, cause it needs space in the repository but very little space. I have checked this and it's about 1 kb per tag.
    In a world where we have hard drives large enough that 1KB is .00000013% of the total drive space (750GB drive), 1KB is negligible.

  9. #9

    Alternate for labels using svn ant tasks

    Hi

    The problem with this method is that if I want to run a build file multiple files, then the tags will be created multiple times even though it doesn't takes space.

    I am using apache ant based build scripts right now. And I am unable to use svn info target correctly?

    Using svn info, one can get the latest revision of the repository and use revision attribute in all the svn ant tasks. In other way, it will act as a label.

    But can anyone specify the correct syntax for the same?

    Ankush

  10. #10
    The dirty way to do this using ant script is to

    checkout the top most folder
    use svn status (task) to get the HEAD revision number.

    Then use this revision number in all the svn tasks. It should be same as labelling.

  11. #11
    ok, so I use to work with Clear Case and it had labels so I wanted to use the same thing is SVN. I have been using SVN a lot for a few months - read the book and find myself hitting the SVN wall when trying to individually label/tag files or folders.
    For ppl that don't understand labeling, its like putting an unversioned property on may files/folders that make up a baseline that you can search on later to reconstruct your baseline. Not a snapshot of all files in a folder at a given time, only the ones you are interested in.
    I have read the forums and mailing list seeing ppl say that I can use tags, properties, pegged versions, revisions, externals and what ever else to mark a folder/file at a particular point - but its not labelling. It is not the same granularity.
    I want to label different files with different labels without having to create a folder for each file each time it is issued/baselined.
    Yes I can copy the selected files to a tag folder, but the files I am interest in may be spread across the repo and externals only work to folders.
    Yes I can use unversioned but how do I search from them later without the revision number?
    I don't want to create custom scripts, dirty fixes, heaps of folders on or under the head or properties that I can't search on.
    Please add labels to subversion!

  12. #12
    This isn't a place to ask for Subversion features. Write up a proposal including a design document, present it to the developers mailing list, if it gets approved it still needs to be coded - and unless you're doing the coding, you'll have to convince other people that it should be done and/or fund it.

Similar Threads

  1. Equivalent of labelling in SVN.
    By saggi_crishna in forum Version Control Practices
    Replies: 4
    Last Post: 10-22-2009, 07:53 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •