Reputation: 81
Im trying to downgrade to 3.0.5 with terminal and typed
git reset --hard e85ea0e79c6d894c120cda4ee8ee10fe6745e187
but error says
fatal: not a git repository (or any of the parent directories): .git
how can I solve??
Upvotes: 2
Views: 10211
Reputation: 596
There a documentation to switch to spesific flutter version here. No need for Third package/library.
Find your desired Flutter version on the Flutter SDK archive.
Navigate to the Flutter SDK: cd /path/to/flutter
Tip! You can find the Flutter SDK's path using
flutter doctor --verbose
.
git checkout <Flutter version>
After following the step, if you try to run flutter doctor --version
you will be informed that you are on the [user-branch]
channel.
Check the available channel: flutter channel
Choose the channel: flutter channel <Channel name>
Upvotes: 0
Reputation: 723
**** 2024 EDIT ***
it is no longer possible to downgrade flutter with this command. the flutter downgrade command downgra only to the penultimate version.
**** end of 2024 EDIT****
flutter downgrade 3.0.5
Change the version from 3.0.5
to as your wish
Run this command.
Upvotes: 6
Reputation: 44220
Stop installing and uninstalling versions! Get yourself an install of package:fvm, aka https://pub.dev/packages/fvm, aka http://fvm.app. You can have per-project selection of any flutter version that has been published, as well as keep the latest version as your global default.
Upvotes: 4