-
Notifications
You must be signed in to change notification settings - Fork 122
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
IEP-1043: Allow the user to configure IDF_TOOLS_PATH (#988)
* IEP-1043: configuration property added to configure the tools installation directory
- Loading branch information
Showing
19 changed files
with
155 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,13 +18,14 @@ | |
import org.eclipse.cdt.managedbuilder.envvar.IBuildEnvironmentVariable; | ||
|
||
import com.espressif.idf.core.logging.Logger; | ||
import com.espressif.idf.core.util.IDFUtil; | ||
import com.espressif.idf.core.util.StringUtil; | ||
|
||
/** | ||
* @author Kondal Kolipaka <[email protected]> | ||
* | ||
*/ | ||
@SuppressWarnings("restriction") //$NON-NLS-1$ | ||
@SuppressWarnings("restriction") | ||
public class IDFEnvironmentVariables | ||
{ | ||
/** | ||
|
@@ -127,17 +128,21 @@ public Map<String, String> getSystemEnvMap() | |
IEnvironmentVariableManager buildEnvironmentManager = CCorePlugin.getDefault().getBuildEnvironmentManager(); | ||
IEnvironmentVariable[] variables = buildEnvironmentManager.getVariables((ICConfigurationDescription) null, | ||
true); | ||
Map<String, String> envMap = new HashMap<>(); | ||
Map<String, String> envMap = IDFUtil.getSystemEnv(); | ||
if (variables != null) | ||
{ | ||
for (IEnvironmentVariable iEnvironmentVariable : variables) | ||
{ | ||
String key = iEnvironmentVariable.getName(); | ||
if (key.equals(IDFCorePreferenceConstants.IDF_TOOLS_PATH)) | ||
{ | ||
continue; | ||
} | ||
String value = iEnvironmentVariable.getValue(); | ||
envMap.put(key, value); | ||
} | ||
} | ||
|
||
return envMap; | ||
} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.