ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dona...@apache.org
Subject cvs commit: jakarta-ant/proposal/myrmidon/src/java/org/apache/antlib/build Patch.java
Date Sun, 10 Feb 2002 00:26:40 GMT
donaldp     02/02/09 16:26:40

  Modified:    proposal/myrmidon/src/java/org/apache/antlib/build
                        Patch.java
  Log:
  Experiment with an alternate pattern for writing tasks wrapped around native exes
  
  Revision  Changes    Path
  1.3       +2 -17     jakarta-ant/proposal/myrmidon/src/java/org/apache/antlib/build/Patch.java
  
  Index: Patch.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/proposal/myrmidon/src/java/org/apache/antlib/build/Patch.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- Patch.java	6 Feb 2002 13:33:07 -0000	1.2
  +++ Patch.java	10 Feb 2002 00:26:40 -0000	1.3
  @@ -44,8 +44,6 @@
   
       /**
        * Ignore whitespace differences.
  -     *
  -     * @param ignore The new Ignorewhitespace value
        */
       public void setIgnorewhitespace( final boolean ignorewhitespace )
       {
  @@ -54,8 +52,6 @@
   
       /**
        * The file to patch.
  -     *
  -     * @param file The new Originalfile value
        */
       public void setOriginalfile( final File originalFile )
       {
  @@ -64,8 +60,6 @@
   
       /**
        * The file containing the diff output.
  -     *
  -     * @param file The new Patchfile value
        */
       public void setPatchfile( final File patchFile )
       {
  @@ -74,8 +68,6 @@
   
       /**
        * Work silently unless an error occurs.
  -     *
  -     * @param q The new Quiet value
        */
       public void setQuiet( final boolean quiet )
       {
  @@ -84,8 +76,6 @@
   
       /**
        * Assume patch was created with old and new files swapped.
  -     *
  -     * @param r The new Reverse value
        */
       public void setReverse( final boolean reverse )
       {
  @@ -112,10 +102,8 @@
   
           final ExecManager execManager = (ExecManager)getService( ExecManager.class );
           final Execute2 exe = new Execute2( execManager );
  -        setupLogger( exe );
   
  -        final Commandline cmd = buildCommand();
  -        exe.setCommandline( cmd );
  +        buildCommand( exe.getCommandline() );
   
           try
           {
  @@ -148,11 +136,9 @@
           }
       }
   
  -    private Commandline buildCommand()
  +    private void buildCommand( final Commandline cmd )
       {
  -        final Commandline cmd = new Commandline();
           cmd.setExecutable( "patch" );
  -
           if( m_backups )
           {
               cmd.addArgument( "-b" );
  @@ -185,6 +171,5 @@
           {
               cmd.addArgument( m_originalFile );
           }
  -        return cmd;
       }
   }
  
  
  

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message