The files in this tree are an INITIAL start at at "Perforce" plug-in
to the Java build tool named "ant".
There's a bootstrap issue to be dealt with, so follow carefully:
1. You need to get the JDK and ANT built and installed.
Be sure to set ANT_HOME and JDK_HOME in your environment
and try a few tests first.
2. Extract this set of files, preserving directory structure.
(If you don't extract it into ANT_HOME, be prepared to modify
line 21 of 'build.xml' so that it points to ${ANT_HOME}/lib/ant.jar.
Otherwise, "p4sync.java" won't compile.)
3. Type "ant" and watch it build one .class file (p4sync.class). It
will put this into dist/lib/p4sync.jar.
4. Test it out, by running including that 'dist/lib/p4sync.jar' into
your path and then building using
ant -f build.users-p4sync.xml
If it doesn't find the
org.apache.tools.ant.taskdefs.optional.perforce.p4sync
method then your CLASSPATH isn't set right or you didn't compile
it after all - check the output from step #3 again.
Things to do:
1. Document this.
What it does:
If you include the task:
<p4sync dir="src" force="no" date="2000/04/01"
label="labelname" revision="#have" />
into your build.xml file, it'll run a "p4 sync" on that directory
(it assumes it's part of a workspace that's mapped in)
to the specified revision.
And...
1. "dir" is mandatory, the rest are optional;
2. If you specify date, midnight is implied.
3. You cannot specify more than one of (date, label, revision).
4. Any "sync" error is considered a fatal error, and a BuildException
is returned.
For the label/date parms, it'll prepend "@" as needed; for
the revision, it'll prepend "#" as needed.
Examples:
<p4sync dir="src" force="no" date="2000/01/02" />
<p4sync dir="src" force="no" date="@2000/01/02" />
<p4sync dir="src" force="no" revision="2" />
<p4sync dir="src" force="no" revision="#2" />
<p4sync dir="src" force="no" label="release1" />
<p4sync dir="src" force="no" label="@release1" />