Skip to content

Bring projects, wikis, and teams together with AI. AppFlowy is the AI collaborative workspace where you achieve more without losing control of your data. The leading open source Notion alternative.

ci: no more `sed`

Hieu288afbe68bec
diff --git a/.github/workflows/dart_lint.yml b/.github/workflows/dart_lint.yml
index 73378109ec..56cc033292 100644
--- a/.github/workflows/dart_lint.yml
+++ b/.github/workflows/dart_lint.yml
@@ -35,8 +35,7 @@ jobs:
working-directory: frontend/app_flowy
run: |
flutter pub run easy_localization:generate -S ./assets/translations -f keys -O lib/generated -o locale_keys.g.dart
- sed -i '/generate: true/s/true/false/g' pubspec.yaml
- flutter pub get
+ flutter packages pub get
flutter packages pub run build_runner build --delete-conflicting-outputs
- name: flutter analyze
working-directory: frontend/app_flowy
diff --git a/.github/workflows/dart_test.yml b/.github/workflows/dart_test.yml
index 4261e6e9b9..6ce615bedc 100644
--- a/.github/workflows/dart_test.yml
+++ b/.github/workflows/dart_test.yml
@@ -35,8 +35,7 @@ jobs:
working-directory: frontend/app_flowy
run: |
flutter pub run easy_localization:generate -S ./assets/translations -f keys -O lib/generated -o locale_keys.g.dart
- sed -i '/generate: true/s/true/false/g' pubspec.yaml
- flutter pub get
+ flutter packages pub get
flutter packages pub run build_runner build --delete-conflicting-outputs
- name: Build FlowySDK
working-directory: frontend
diff --git a/frontend/scripts/makefile/flutter.toml b/frontend/scripts/makefile/flutter.toml
index 02ff1f7ccd..753b57132a 100644
--- a/frontend/scripts/makefile/flutter.toml
+++ b/frontend/scripts/makefile/flutter.toml
@@ -187,33 +187,19 @@ script = [
"""
cd app_flowy
flutter clean
- sed -i '/generate: true/s/true/false/g' pubspec.yaml
- flutter pub get
+ flutter packages pub get
flutter packages pub run build_runner build --delete-conflicting-outputs
"""
]
-# TODO: Add support for Windows.
-# [tasks.generate_freezed_files.windows]
-# script_runner = "@duckscript"
-# script = [
-# """
-# cd ./app_flowy/
-# exec cmd.exe /c flutter clean
-# exec cmd.exe /c flutter pub get
-# exec cmd.exe /c flutter pub run easy_localization:generate -S assets/translations/
-# exec cmd.exe /c flutter pub run easy_localization:generate -f keys -o locale_keys.g.dart -S assets/translations
-# """
-# ]
-
-[tasks.generate_freezed_files.mac]
-script_runner = "@shell"
+[tasks.generate_freezed_files.windows]
+script_runner = "@duckscript"
script = [
"""
- cd app_flowy
- flutter clean
- sed -i '' '/generate: true/s/true/false/g' pubspec.yaml
- flutter pub get
- flutter packages pub run build_runner build --delete-conflicting-outputs
+ cd ./app_flowy/
+ exec cmd.exe /c flutter clean
+ exec cmd.exe /c flutter packages pub get
+ exec cmd.exe /c flutter packages pub get
+ exec cmd.exe /c flutter packages pub run build_runner build --delete-conflicting-outputs
"""
]
\ No newline at end of file