diff --git a/.gitignore b/.gitignore index 10d6d8a92..1daa455e4 100644 --- a/.gitignore +++ b/.gitignore @@ -33,8 +33,8 @@ build/macosx/libastylej* build/macosx/appbundler*.jar build/macosx/appbundler*.zip build/macosx/appbundler -build/macosx/appbundler-1.0ea-arduino2 -build/macosx/appbundler-1.0ea-upstream1 +build/macosx/appbundler-1.0ea-arduino*.zip +build/macosx/appbundler-1.0ea-upstream*.zip build/linux/work/ build/linux/dist/*.tar.gz build/linux/dist/*.tar.bz2 diff --git a/arduino-core/src/processing/app/BaseNoGui.java b/arduino-core/src/processing/app/BaseNoGui.java index 8aeffcc15..6dbba24a0 100644 --- a/arduino-core/src/processing/app/BaseNoGui.java +++ b/arduino-core/src/processing/app/BaseNoGui.java @@ -186,21 +186,8 @@ public class BaseNoGui { } static public File getContentFile(String name) { - File path = new File(System.getProperty("user.dir")); - - if (OSUtils.isMacOS()) { - if (System.getProperty("WORK_DIR") != null) { - path = new File(System.getProperty("WORK_DIR")); - } else { - try { - path = new File(BaseNoGui.class.getProtectionDomain().getCodeSource().getLocation().toURI().getPath()).getParentFile(); - } catch (URISyntaxException e) { - throw new RuntimeException(e); - } - } - } - - return new File(path, name); + File installationFolder = new File(System.getProperty("APP_DIR")); + return new File(installationFolder, name); } static public TargetPlatform getCurrentTargetPlatformFromPackage(String pack) { @@ -976,11 +963,6 @@ public class BaseNoGui { preferencesFile = args[i]; continue; } - if (args[i].equals("--curdir")) { - i++; - currentDirectory = args[i]; - continue; - } } // run static initialization that grabs all the prefs diff --git a/arduino-core/src/processing/app/helpers/CommandlineParser.java b/arduino-core/src/processing/app/helpers/CommandlineParser.java index 04805ec3e..e4a23fece 100644 --- a/arduino-core/src/processing/app/helpers/CommandlineParser.java +++ b/arduino-core/src/processing/app/helpers/CommandlineParser.java @@ -146,11 +146,8 @@ public class CommandlineParser { continue; } if (args[i].equals("--curdir")) { - i++; - if (i >= args.length) - BaseNoGui.showError(null, _("Argument required for --curdir"), 3); - // Argument should be already processed by Base.main(...) - continue; + BaseNoGui.showError(null, _("--curdir no longer supported"), 3); + return; } if (args[i].equals("--buildpath")) { i++; diff --git a/build/build.xml b/build/build.xml index d4b54fb22..2adb126dc 100644 --- a/build/build.xml +++ b/build/build.xml @@ -305,16 +305,17 @@ - - - - + + + + - + @@ -336,11 +338,12 @@ -