aspose file tools
The moose likes Ant, Maven and Other Build Tools and the fly likes ANT CVS checkout problem Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Reply Bookmark "ANT CVS checkout problem" Watch "ANT CVS checkout problem" New topic
Author

ANT CVS checkout problem

starrman777
Greenhorn

Joined: Mar 23, 2005
Posts: 6
I have a CVS directory structure like this:

home
dev
myapp
src
com
companyname
(etc... )

I have set up a local src directory

<property name="build" location="build" />
<property name="src" location="${build}/src" />

<mkdir dir="${build}" />
<mkdir dir="${src}" />

I would like to checkout from CVS only the com directory on down so that the local directory structure would be

build
src
com
companyname
(etc... )

Here is what I have so far

<input message="Enter the name of the branch that you want to get from CVS"
addproperty="cvs.branch.name" />

<cvs cvsRoot="${cvs.root}"
package="home/dev/myapp/src/com"
command="checkout -r ${cvs.branch.name}"
dest="${src}"/>


I'm using ANT 1.6.2...

Any ideas?
Carol Enderlin
drifter
Ranch Hand

Joined: Oct 10, 2000
Posts: 1348
I put an "illegal word" in my carefully crafted post and it disappeared so I'll try again.

What isn't working? Are you getting errors?

I checked out a subdirectory in eclipse and it used this to put it in the src dir without the project1 and mydir directories:

cvs co -d "src" -P -A "/project1/mydir/src"

In this Guide to cvs commands it sounds like the -d part is what you need to not end up with all the extra directories.
starrman777
Greenhorn

Joined: Mar 23, 2005
Posts: 6
Thank You. Very helpful.

The -d is what I was missing.

Now my checkout command looks like this:
<cvs cvsRoot="${cvs.root}"
package="home/dev/myapp/src/com"
command="checkout -d 'com' -r ${cvs.branch.name}"
dest="${src}"/>

Thanks Again!
Eric
Carol Enderlin
drifter
Ranch Hand

Joined: Oct 10, 2000
Posts: 1348
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: ANT CVS checkout problem
 
Similar Threads
Ant, JAR files, and the associated 'Paths' created in the JAR file - help!
Question on Ant script error in my build.xml file in the Eclipse IDE
conditional creating of a directory
Web App Deployment using Ant
Howto run specific JUnit tests in ant?