-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
64 lines (51 loc) · 1.89 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
SHELL=/bin/bash
.PHONY: $(shell egrep -oh ^[a-zA-Z0-9][a-zA-Z0-9_-]+: $(MAKEFILE_LIST) | sed 's/://')
# プロジェクトのクリーンを行う
.PHONY: clean
clean:
fvm flutter clean
fvm flutter pub get
fvm flutter pub run build_runner build --delete-conflicting-outputs
# freezed関連のファイルを修正したら、以下の自動生成コマンドを実行してください
.PHONY: run-gen
run-gen:
fvm flutter pub run build_runner build --delete-conflicting-outputs
# format + 静的解析の実行結果を確認する
.PHONY: check
check:
fvm dart format --output=none . > format_result.txt
fvm flutter analyze > analyze_result.txt
fvm flutter test > test_result.txt
# formatを適用する
.PHONY: format
format:
fvm flutter pub run import_sorter:main
fvm dart format .
# pubspec.yamlに記載の全てのpackageのUpdateを行う
.PHONY: pub-upgrade
pub-upgrade:
fvm flutter pub upgrade
# https://docs.flutter.dev/deployment/android
.PHONY: build-android-dev
build-android-dev:
fvm flutter build apk --release --dart-define-from-file=dart_define/development.json
.PHONY: build-android-stg
build-android-stg:
fvm flutter build apk --release --dart-define-from-file=dart_define/staging.json
.PHONY: build-android-prod
build-android-prod:
fvm flutter build apk --release --dart-define-from-file=dart_define/production.json
.PHONY: build-android-bundle
build-android-bundle:
fvm flutter build appbundle --release --dart-define-from-file=dart_define/production.json
# https://docs.flutter.dev/deployment/ios
.PHONY: build-ios
build-ios:
fvm flutter build ios --release --dart-define-from-file=dart_define/production.json
.PHONY: build-ipa
build-ipa:
fvm flutter build ipa --release --dart-define-from-file=dart_define/production.json
# https://docs.flutter.dev/deployment/macos
.PHONY: build-macos
build-macos:
fvm flutter build macos --release --dart-define-from-file=dart_define/production.json