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

Re: identifying release-dir

From: Lorenz <lorenznl_at_yahoo.com>
Date: Tue, 06 Oct 2009 05:43:25 +0000

Marc Lustig wrote:

>Hi,
>
>we want a pre-commit-script that prevents modifying any file under a
>tagged-version.
>The challenge is that different projects use different layouts under tags.
>These are the layouts that I discovered:
>
>1) project/tags/1.1.1
>2) project/tags/subproject/1.1.1
>3) project/tags/subproject-1.1.1
>4) project/tags/subproject/subproject-1.1.1
>
>
>The only common thing is (due to Maven) that the versions
>- are below the tags-dir
>- have 3 numbers - major, middle and minor ("digits.digits.digits")
>
>I could already resolve the layouts 1 and 2.
>Could somebody give me a hint how to use bash-commands like expr or sed to
>identify the layouts 3) and 4).
>
>The reg-exp would probably look somewhat like this:
>"([0-9]*)\.([0-9]*)\.([0-9]*)"
>
>The number of digits are arbitrary.

something like

> svnlook ... | gawk '/.*[/]tags[/].*[0-9]+[.][0-9]+[.][0-9]+[/]/ {tagfound=1} END {return tagfound}

-- 
Lorenz
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2403948
To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-10-06 07:45:01 CEST

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