From ed82cb69e8903df2ed8bc0d4a71b9650edba964f Mon Sep 17 00:00:00 2001 From: Conor MacNeill Date: Mon, 3 Feb 2003 14:07:00 +0000 Subject: [PATCH] Added a revision attribute, a synonym for label PR: 13847 Submitted By: Steven Newton git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@273964 13f79535-47bb-0310-9956-ffa450edef68 --- .../ant/taskdefs/optional/pvcs/Pvcs.java | 27 +++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/src/main/org/apache/tools/ant/taskdefs/optional/pvcs/Pvcs.java b/src/main/org/apache/tools/ant/taskdefs/optional/pvcs/Pvcs.java index b92f067ca..27e6be5d4 100644 --- a/src/main/org/apache/tools/ant/taskdefs/optional/pvcs/Pvcs.java +++ b/src/main/org/apache/tools/ant/taskdefs/optional/pvcs/Pvcs.java @@ -99,6 +99,11 @@ import org.apache.tools.ant.types.Commandline; * update those files that have a modification time (in PVCS) that is newer * than the existing workfile. * + * 25-10-2002

Added a revision attribute that currently is a + * synonym for label, but in a future release the behavior of the label + * attribute will change to use the -v option of GET. See bug #13847 for + * discussion. + * * @author Thomas Christensen * @author Don Jeffery * @author Steven E. Newton @@ -112,6 +117,7 @@ public class Pvcs extends org.apache.tools.ant.Task { private String force; private String promotiongroup; private String label; + private String revision; private boolean ignorerc; private boolean updateOnly; private String filenameFormat; @@ -262,6 +268,11 @@ public class Pvcs extends org.apache.tools.ant.Task { } else { if (getLabel() != null) { commandLine.createArgument().setValue("-r" + getLabel()); + } else { + if (getRevision() != null) { + commandLine.createArgument().setValue("-r" + + getRevision()); + } } } @@ -572,6 +583,22 @@ public class Pvcs extends org.apache.tools.ant.Task { label = l; } + /** + * Get value of revision + * @return String + */ + public String getRevision() { + return revision; + } + + /** + * Only files with this revision are extract; optional. + * @param r String + */ + public void setRevision(String r) { + revision = r; + } + /** * Get value of ignorereturncode * @return String