fvm
fvm copied to clipboard
Option to specify FVM_HOME directory
Describe the solution you'd like I want to be able to change fvm's default directory from ~/fvm using environmental variables. I recommend using FVM_HOME.
Describe alternatives you've considered Nothing, as far as I know currently it is not an option to change from ~/fvm
See: https://github.com/leoafarias/fvm/issues/489#issuecomment-2726083364
Thanks for the request, @pbartyik! This is already supported via environment variables 🎉
Solution
You can change FVM's cache directory using:
Recommended:
export FVM_CACHE_PATH="$HOME/custom/path"
Legacy (still works):
export FVM_HOME="$HOME/custom/path"
Usage
Add to your shell config (~/.bashrc, ~/.zshrc, etc.):
export FVM_CACHE_PATH="$HOME/Development/flutter-sdks"
Then restart your terminal or run source ~/.bashrc.
Temporary override:
FVM_CACHE_PATH=/tmp/fvm fvm install stable
Documentation
Full details in our configuration guide:
https://fvm.app/documentation/getting-started/configuration
Closing as this functionality already exists. Let me know if you need help setting it up!
Feature already supported via FVM_CACHE_PATH environment variable