Skip to content

Commit 505ae07

Browse files
author
jantje
committed
support the environment variable runtime.ide.path #1547
1 parent 3b0758e commit 505ae07

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

io.sloeber.core/src/io/sloeber/core/common/Const.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ public class Const {
6767
public static final String ARDUINO_NATURE_ID = "io.sloeber.arduinonature";
6868
public static final String KEY_LAST_USED_EXAMPLES = "Last used Examples";
6969
public static final String SLOEBER_HOME = "SLOEBER_HOME";
70+
public static final String RUNTIME_IDE_PATH = "runtime.ide.path";
7071
public static final String LOCAL = "local";
7172

7273
// Folder and file Information

io.sloeber.core/src/io/sloeber/core/toolchain/SloeberProjectVariableSupplier.java

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,6 @@
1818
//SloeberConfigurationVariableSupplier
1919
public class SloeberProjectVariableSupplier implements IProjectEnvironmentVariableSupplier {
2020

21-
22-
2321
private static BuildEnvironmentVariable get_EXTRA_TIME_UTC() {
2422
Date d = new Date();
2523
long current = d.getTime() / 1000;
@@ -51,6 +49,9 @@ private static BuildEnvironmentVariable get_SLOEBER_HOME() {
5149
return new BuildEnvironmentVariable(SLOEBER_HOME, Common.sloeberHome);
5250
}
5351

52+
private static BuildEnvironmentVariable get_RUNTIME_IDE_PATH() {
53+
return new BuildEnvironmentVariable(RUNTIME_IDE_PATH, Common.sloeberHome);
54+
}
5455

5556
@Override
5657
public IBuildEnvironmentVariable getVariable(String variableName, IManagedProject project,
@@ -66,6 +67,8 @@ public IBuildEnvironmentVariable getVariable(String variableName, IManagedProjec
6667
return get_EXTRA_TIME_DTS();
6768
case SLOEBER_HOME:
6869
return get_SLOEBER_HOME();
70+
case RUNTIME_IDE_PATH:
71+
return get_RUNTIME_IDE_PATH();
6972
}
7073
return null;
7174
}
@@ -78,6 +81,8 @@ public IBuildEnvironmentVariable[] getVariables(IManagedProject project, IEnviro
7881
retValues.put(EXTRA_TIME_ZONE, get_EXTRA_TIME_ZONE());
7982
retValues.put(EXTRA_TIME_DTS, get_EXTRA_TIME_DTS());
8083
retValues.put(SLOEBER_HOME, get_SLOEBER_HOME());
84+
retValues.put(RUNTIME_IDE_PATH, get_RUNTIME_IDE_PATH());
85+
8186
return retValues.values().toArray(new BuildEnvironmentVariable[retValues.size()]);
8287
}
8388

0 commit comments

Comments
 (0)