Author: [email protected]
Date: Fri May 15 13:24:52 2009
New Revision: 5397
Modified:
trunk/dev/core/src/com/google/gwt/dev/GWTShell.java
Log:
Fixing suport for deprecated system property com.google.gwt.shell.outdir,
which should affect both workdir and outdir.
Review by: spoon
Modified: trunk/dev/core/src/com/google/gwt/dev/GWTShell.java
==============================================================================
--- trunk/dev/core/src/com/google/gwt/dev/GWTShell.java (original)
+++ trunk/dev/core/src/com/google/gwt/dev/GWTShell.java Fri May 15 13:24:52
2009
@@ -1,12 +1,12 @@
/*
* Copyright 2008 Google Inc.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License"); you may
not
* use this file except in compliance with the License. You may obtain a
copy of
* the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
@@ -33,7 +33,7 @@
/**
* The main executable class for the hosted mode shell.
- *
+ *
* @deprecated Use {...@link HostedMode} instead
*/
@Deprecated
@@ -104,6 +104,10 @@
}
public File getOutDir() {
+ if (System.getProperty("com.google.gwt.shell.outdir") != null) {
+ // deprecated old property way to set outputs
+ return new File(System.getProperty("com.google.gwt.shell.outdir"));
+ }
return outDir;
}
@@ -113,9 +117,7 @@
@Override
public File getWorkDir() {
- if (System.getProperty("com.google.gwt.shell.outdir") != null) {
- return new File(System.getProperty("com.google.gwt.shell.outdir"));
- }
+ File workdir = new File(getOutDir(), ".gwt-tmp");
return new File(getOutDir(), ".gwt-tmp");
}
@@ -140,12 +142,6 @@
GWTShell gwtShell = new GWTShell();
ArgProcessor argProcessor = new ArgProcessor(gwtShell.options, false,
false);
- // deprecated old property way to set outputs
- if (System.getProperty("com.google.gwt.shell.outdir") != null) {
- gwtShell.options.setOutDir(new
File(System.getProperty("com.google.gwt.shell.outdir")));
- gwtShell.options.setWorkDir(new
File(System.getProperty("com.google.gwt.shell.outdir")));
- }
-
if (argProcessor.processArgs(args)) {
gwtShell.run();
// Exit w/ success code.
@@ -255,7 +251,7 @@
protected boolean initModule(String moduleName) {
/*
* Not used in legacy mode due to GWTShellServlet playing this role.
- *
+ *
* TODO: something smarter here and actually make GWTShellServlet less
* magic?
*/
--~--~---------~--~----~------------~-------~--~----~
http://groups.google.com/group/Google-Web-Toolkit-Contributors
-~----------~----~----~----~------~----~------~--~---