2

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??

3 Answers 3

7

**** 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.

Sign up to request clarification or add additional context in comments.

Comments

4

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.

2 Comments

Of course, my preferred tool for this now is puro.dev, which is faster, more flexible, and more efficient.
Thanks. Very helpful. I wish I had read this answer sooner.
0

There a documentation to switch to spesific flutter version here. No need for Third package/library.


To switch to a specific Flutter version:

  1. Find your desired Flutter version on the Flutter SDK archive.

  2. Navigate to the Flutter SDK: cd /path/to/flutter

Tip! You can find the Flutter SDK's path using flutter doctor --verbose.

  1. Use git checkout to switch to your desired Flutter version: 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.


To back to the latest version

  1. Check the available channel: flutter channel

  2. Choose the channel: flutter channel <Channel name>

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.