본문 바로가기

개발/모바일 앱

[Flutter] 플러터 버전 바꾸기 (다운그레이드, 업그레이드)

반응형

[Flutter] 플러터 버전 바꾸기 (다운그레이드, 업그레이드)

 

플러터를 사용하다가 실수로 업그레이드 하거나 하는 이유로,

잘 빌드되던 기존 코드가 빌드에 실패하는 불상사가 발생하곤 한다.

 

이 때는 당황하지 말고 플러터 버전을 다운그레이드하면 된다!

 

1. 아래 링크를 타고 들어가면, flutter 공식 깃헙의 tags 페이지로 진입한다.

2. 여기서 다운그레이드를 원하는 버전의 태그의 commit ID를 복사한다.

3. flutter가 설치되어있는 폴더(디렉터리)로 이동한다.

4. git reset --hard <2번에서 복사한 commit ID>

5. 끝! 이제 플러터 프로젝트를 다시 로드하고 빌드해보자.

 

https://github.com/flutter/flutter/tags

 

GitHub - flutter/flutter: Flutter makes it easy and fast to build beautiful apps for mobile and beyond

Flutter makes it easy and fast to build beautiful apps for mobile and beyond - GitHub - flutter/flutter: Flutter makes it easy and fast to build beautiful apps for mobile and beyond

github.com

반응형