Reputation: 37484
I need to set some proxy settings for my Android Studio (v1.5.1) project (on Ubuntu). Every time I need it (e.g. when downloading an external library), Android Studio proposes to write them to gradle.properties
, with no other option.
Since this file is version-controlled on a git repository, I need to set them somewhere else.
Any suggestion?
Upvotes: 2
Views: 896
Reputation: 365138
You can use the /home/user/.gradle/gradle.properties
file.
This file is not under version control and it is used by all projects in your machine. This file is used by gradle without any setting, and you can use it to store some reserved data for example.
The configuration is applied in following order (if an option is configured in multiple locations the last one wins):
gradle.properties
in project build dir.gradle.properties
in gradle user home.Upvotes: 3
Reputation: 33438
You will need to add it to gradle.properties
. You can just mark the file to be ignored by git so that you do not accidentally check in the proxy details.
OR
just momentarily switch to a public network when the proxy is blocking some network resources.
Upvotes: 2