Return the correct expanded execution string after the command started. BLD200204040100
authormentlicher@netbeans.org
Wed, 03 Apr 2002 15:36:04 +0000
changeset 214533fcc793be67
parent 2144 14190ecf9835
child 2146 5185c86f2581
Return the correct expanded execution string after the command started.
This is a fix of issue #21501.
vcscore/src/org/netbeans/modules/vcscore/cmdline/CommandLineVcsDirReader.java
vcscore/src/org/netbeans/modules/vcscore/cmdline/CommandLineVcsDirReaderRecursive.java
vcscore/src/org/netbeans/modules/vcscore/cmdline/ExecuteCommand.java
     1.1 --- a/vcscore/src/org/netbeans/modules/vcscore/cmdline/CommandLineVcsDirReader.java	Wed Apr 03 15:02:22 2002 +0000
     1.2 +++ b/vcscore/src/org/netbeans/modules/vcscore/cmdline/CommandLineVcsDirReader.java	Wed Apr 03 15:36:04 2002 +0000
     1.3 @@ -48,6 +48,7 @@
     1.4      private Hashtable vars = null ;
     1.5      //private VcsCacheDir dir=null ;
     1.6      private String path;
     1.7 +    private String exec;
     1.8  
     1.9      private ArrayList commandOutputListener = new ArrayList(); 
    1.10      private ArrayList commandErrorOutputListener = new ArrayList(); 
    1.11 @@ -90,6 +91,7 @@
    1.12          //dir.setName (VcsUtilities.getFileNamePart (path));
    1.13          //if (path.length() == 0) vars.put("DIR", "."); // NOI18N
    1.14          D.deb ("DIR="+(String)vars.get("DIR")); // NOI18N
    1.15 +        this.exec = (String) list.getProperty(VcsCommand.PROPERTY_EXEC);
    1.16      }
    1.17  
    1.18  
    1.19 @@ -166,7 +168,7 @@
    1.20       * Get the updated execution string. It may contain user input now.
    1.21       */
    1.22      public String getExec() {
    1.23 -        return (String) list.getProperty(VcsCommand.PROPERTY_EXEC);
    1.24 +        return exec;
    1.25      }
    1.26      
    1.27      /**
    1.28 @@ -445,7 +447,7 @@
    1.29  
    1.30      //-------------------------------------------
    1.31      public void run() {
    1.32 -        String exec = (String) list.getProperty(VcsCommand.PROPERTY_EXEC);
    1.33 +        //String exec = (String) list.getProperty(VcsCommand.PROPERTY_EXEC);
    1.34          exec = Variables.expand(vars, exec, false).trim();
    1.35          //fileSystem.debug("LIST: "+exec); // NOI18N
    1.36  
     2.1 --- a/vcscore/src/org/netbeans/modules/vcscore/cmdline/CommandLineVcsDirReaderRecursive.java	Wed Apr 03 15:02:22 2002 +0000
     2.2 +++ b/vcscore/src/org/netbeans/modules/vcscore/cmdline/CommandLineVcsDirReaderRecursive.java	Wed Apr 03 15:36:04 2002 +0000
     2.3 @@ -42,6 +42,7 @@
     2.4      private Hashtable vars = null;
     2.5      //private VcsCacheDir dir = null;
     2.6      private String path = null;
     2.7 +    private String exec;
     2.8  
     2.9      private ArrayList commandOutputListener = new ArrayList(); 
    2.10      private ArrayList commandErrorOutputListener = new ArrayList(); 
    2.11 @@ -73,6 +74,7 @@
    2.12          //dir.setName(VcsUtilities.getFileNamePart(path));
    2.13          //if (path.length() == 0) vars.put("DIR", "."); // NOI18N
    2.14          D.deb("DIR="+(String)vars.get("DIR")); // NOI18N
    2.15 +        this.exec = (String) listSub.getProperty(VcsCommand.PROPERTY_EXEC);
    2.16      }
    2.17  
    2.18      /**
    2.19 @@ -141,7 +143,7 @@
    2.20       * Get the updated execution string. It may contain user input now.
    2.21       */
    2.22      public String getExec() {
    2.23 -        return (String) listSub.getProperty(VcsCommand.PROPERTY_EXEC);
    2.24 +        return exec;
    2.25      }
    2.26      
    2.27      /**
    2.28 @@ -380,7 +382,7 @@
    2.29       */
    2.30  
    2.31      public void run() {
    2.32 -        String exec = (String) listSub.getProperty(VcsCommand.PROPERTY_EXEC);
    2.33 +        //String exec = (String) listSub.getProperty(VcsCommand.PROPERTY_EXEC);
    2.34          exec = Variables.expand(vars, exec, false).trim();
    2.35          //fileSystem.debug("LIST_SUB: "+exec); // NOI18N
    2.36  
     3.1 --- a/vcscore/src/org/netbeans/modules/vcscore/cmdline/ExecuteCommand.java	Wed Apr 03 15:02:22 2002 +0000
     3.2 +++ b/vcscore/src/org/netbeans/modules/vcscore/cmdline/ExecuteCommand.java	Wed Apr 03 15:36:04 2002 +0000
     3.3 @@ -509,6 +509,7 @@
     3.4          E.deb("runClass: "+className); // NOI18N
     3.5          boolean success = true;
     3.6          Class execClass = null;
     3.7 +        preferredExec = exec;
     3.8          try {
     3.9              execClass =  Class.forName(className, true,
    3.10                                         org.openide.TopManager.getDefault().currentClassLoader());