Added the option to use custom paths for the platforms, packages, cache and projects directories and added the option to turn on/off telemetry #3974
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR adds the capacity to use custom paths for the platforms, packages, cache and projects directories by adding a setting for each of them and a setting to enable or disable telemetry which should solve issue #898.
It works by assigning the configuration value of the environment variables:
In the case of the directories if the configuration has some value it will be assigned to the environment variable but if the configuration is null it won't create the environment variable and platformio will use the default directories.
This ability to use custom paths allows the user use a custom platformio installation like installing plaformio in a USB drive and carry all the platforms and toolchains on the go.
Currently there is some obligatory use of the
%USER%/.platformio
directory for theappstate.json
,homestate.json
files and.cache/tmp
directory but i was able to work from a USB drive without any problem.