I work on a Flutter application on two different PC's and would like the Flutter version to be the same for both. I am on the dev
channel and when I do a flutter upgrade
it ugrades to the latest version in that channel.
Two days ago I did a flutter upgrade
on one PC and it went to version 1.2.2
. Today on my other PC I did a flutter upgrade 1.2.2
but it went to version 1.3.2
instead.
Is there a way for me to specify the flutter version when upgrading?
Upgrading the Flutter SDK This command gets the most recent version of the Flutter SDK that's available on your current Flutter channel. If you want an even more recent version of the Flutter SDK, switch to a less stable Flutter channel and then run flutter upgrade .
To Downgrade Flutter SDK First of all Open your Terminal. Then type flutter version It will return all flutter version list. Choose the version that you want to downgrade. Just run the flutter version Suppose I want to use flutter version v1.
This is not yet supported.
There is an open issue for that https://github.com/flutter/flutter/issues/14230
Currently you can use Git commands to get a specific version
$ cd flutter
$ # git checkout [branch, tag or commit hash]
$ git checkout v1.2.2
Update
flutter downgrade <version>
is now supported.
The available versions can be be found in https://github.com/flutter/flutter/tags
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With