Update of /cvsroot/metamorphosis/ruper2/src/java/ant/org/krysalis/ruper2/ant/task
In directory sc8-pr-cvs1:/tmp/cvs-serv23010/src/java/ant/org/krysalis/ruper2/ant/task
Modified Files:
SynchronizeTask.java
Log Message:
Added 'clean' to reposync, removed 'file' -- group only
Index: SynchronizeTask.java
===================================================================
RCS file: /cvsroot/metamorphosis/ruper2/src/java/ant/org/krysalis/ruper2/ant/task/SynchronizeTask.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** SynchronizeTask.java 12 Oct 2003 18:12:08 -0000 1.7
--- SynchronizeTask.java 13 Oct 2003 04:12:02 -0000 1.8
***************
*** 4,14 ****
package org.krysalis.ruper2.ant.task;
- import java.io.File;
-
import org.apache.tools.ant.BuildException;
import org.apache.tools.ant.Project;
import org.apache.tools.ant.Task;
- import org.krysalis.ruper2.FileAssistant;
- import org.krysalis.ruper2.FileUpdater;
import org.krysalis.ruper2.ResourceUpdater;
import org.krysalis.ruper2.RuperException;
--- 4,10 ----
***************
*** 24,28 ****
public class SynchronizeTask extends Task {
- private File m_file = null;
private String m_group = null;
private String m_ruper = RuperConstants.DEFAULT;
--- 20,23 ----
***************
*** 31,41 ****
/**
- * @param file
- */
- public void setFile(File file) {
- m_file = file;
- }
-
- /**
* @param string
*/
--- 26,29 ----
***************
*** 102,126 ****
log("Update Group: " + m_group, Project.MSG_INFO);
!
// Update...
! ruper.updateResourceGroup(new ResourceGroup(m_group));
! }
! else if (null != m_file) {
! log("Update File: " + m_file, Project.MSG_INFO);
!
! // Base files off task base..
! FileAssistant filer = new FileAssistant(getProject().getBaseDir());
!
! FileUpdater updater = new FileUpdater(filer, ruper);
!
! // Update all files [if folder], or one file
! updater.updateFiles(m_file);
}
else
! throw new BuildException("Missing mandatory attributes, one of 'file' or 'group' required.");
!
}
catch (RuperException re) {
! throw new BuildException("Failed to <reposync " + m_file, re);
}
finally {
--- 90,106 ----
log("Update Group: " + m_group, Project.MSG_INFO);
! ResourceGroup group = new ResourceGroup(m_group);
!
// Update...
! ruper.updateResourceGroup(group);
!
! // Cleanup (to remove duplicates)
! ruper.clean(group);
}
else
! throw new BuildException("Missing mandatory attributes, 'group' required.");
}
catch (RuperException re) {
! throw new BuildException("Failed to <reposync " + m_group, re);
}
finally {
-------------------------------------------------------
This SF.net email is sponsored by: SF.net Giveback Program.
SourceForge.net hosts over 70,000 Open Source Projects.
See the people who have HELPED US provide better services:
Click here: http://sourceforge.net/supporters.php
lmpx.com only provides a reader for public news (NNTP) servers. It is not
affiliated with the servers or forums shown here and is not responsible for
the content of articles, which is written by their respective authors.