Reputation: 73
I need react native to use a custom gradle path instead of the default one which is %userprofile%/.gradle
. In Android Studio it's easily changed in the settings (Default settings > Build, Execution, Deployment > Build Tools > Gradle > Service directory path).
However I could not find a way for the react native.
Upvotes: 3
Views: 2647
Reputation: 1086
Set the environment variable GRADLE_USER_HOME
to your custom gradle path.
Upvotes: 2
Reputation: 73
Nevermind, I solved the problem by adding a symlink from .gradle to my custom gradle path by running this from an elevated command prompt:
mklink /D C:\Users\yourusername\.gradle E:\custom\path\to\gradle
Upvotes: 2