mirror of
https://github.com/AppFlowy-IO/AppFlowy.git
synced 2024-08-30 18:12:39 +00:00
chore: upgrade minimum support flutter version, >= 3.3.0 (#1551)
* feat: upgrade flutter version to 3.3.0 for appflowy_editor and appflowy_editor_plugin * feat: upgrade flutter version to 3.3.0 for appflowy * feat: upgrade flutter version to 3.3.0 for CI * chore: update flutter version in ci workflows * chore: fix warnings * chore: fix unuse import * chore: support cargo make dart_unit_test on windows platform * fix: copy to sandbox errors Co-authored-by: nathan <nathan@appflowy.io>
This commit is contained in:
@ -6,7 +6,14 @@
|
||||
|
||||
[tasks.env_check]
|
||||
dependencies = ["echo_env", "install_protobuf"]
|
||||
condition = { env_set = [ "BUILD_FLAG", "RUST_COMPILE_TARGET", "CRATE_TYPE", "TARGET_OS"], channels = ["stable"] }
|
||||
condition = { env_set = [
|
||||
"BUILD_FLAG",
|
||||
"RUST_COMPILE_TARGET",
|
||||
"CRATE_TYPE",
|
||||
"TARGET_OS",
|
||||
], channels = [
|
||||
"stable",
|
||||
] }
|
||||
|
||||
[tasks.appflowy-sdk-dev]
|
||||
mac_alias = "appflowy-sdk-dev-macos"
|
||||
@ -16,22 +23,41 @@ linux_alias = "appflowy-sdk-dev-linux"
|
||||
[tasks.appflowy-sdk-dev-android]
|
||||
category = "Build"
|
||||
dependencies = ["env_check"]
|
||||
run_task = { name = ["setup-crate-type","sdk-build-android", "restore-crate-type"] }
|
||||
run_task = { name = [
|
||||
"setup-crate-type",
|
||||
"sdk-build-android",
|
||||
"restore-crate-type",
|
||||
] }
|
||||
|
||||
[tasks.appflowy-sdk-dev-macos]
|
||||
category = "Build"
|
||||
dependencies = ["env_check"]
|
||||
run_task = { name = ["setup-crate-type","sdk-build", "post-desktop", "restore-crate-type"] }
|
||||
run_task = { name = [
|
||||
"setup-crate-type",
|
||||
"sdk-build",
|
||||
"post-desktop",
|
||||
"restore-crate-type",
|
||||
] }
|
||||
|
||||
[tasks.appflowy-sdk-dev-windows]
|
||||
category = "Build"
|
||||
dependencies = ["env_check"]
|
||||
run_task = { name = ["setup-crate-type","sdk-build", "post-desktop", "restore-crate-type"] }
|
||||
run_task = { name = [
|
||||
"setup-crate-type",
|
||||
"sdk-build",
|
||||
"post-desktop",
|
||||
"restore-crate-type",
|
||||
] }
|
||||
|
||||
[tasks.appflowy-sdk-dev-linux]
|
||||
category = "Build"
|
||||
dependencies = ["env_check"]
|
||||
run_task = { name = ["setup-crate-type","sdk-build", "post-desktop", "restore-crate-type"] }
|
||||
run_task = { name = [
|
||||
"setup-crate-type",
|
||||
"sdk-build",
|
||||
"post-desktop",
|
||||
"restore-crate-type",
|
||||
] }
|
||||
|
||||
|
||||
#
|
||||
@ -90,7 +116,12 @@ script_runner = "@duckscript"
|
||||
description = "Build flowy sdk in release mode"
|
||||
category = "Build"
|
||||
dependencies = ["env_check"]
|
||||
run_task = { name = ["setup-crate-type","sdk-release-build", "post-desktop", "restore-crate-type"] }
|
||||
run_task = { name = [
|
||||
"setup-crate-type",
|
||||
"sdk-release-build",
|
||||
"post-desktop",
|
||||
"restore-crate-type",
|
||||
] }
|
||||
|
||||
#
|
||||
[tasks.sdk-release-build]
|
||||
@ -167,9 +198,19 @@ script_runner = "@duckscript"
|
||||
[tasks.build-test-lib]
|
||||
category = "Build"
|
||||
dependencies = ["env_check"]
|
||||
run_task = { name = ["setup-test-crate-type","build-test-backend", "copy-to-sandbox-folder", "restore-test-crate-type"] }
|
||||
run_task = { name = [
|
||||
"setup-test-crate-type",
|
||||
"build-test-backend",
|
||||
"copy-to-sandbox-folder",
|
||||
"restore-test-crate-type",
|
||||
] }
|
||||
|
||||
[tasks.build-test-backend]
|
||||
mac_alias = "build-test-backend-default"
|
||||
windows_alias = "build-test-backend-widnows"
|
||||
linux_alias = "build-test-backend-default"
|
||||
|
||||
[tasks.build-test-backend-default]
|
||||
private = true
|
||||
script = [
|
||||
"""
|
||||
@ -182,7 +223,39 @@ script = [
|
||||
]
|
||||
script_runner = "@shell"
|
||||
|
||||
[tasks.build-test-backend-widnows]
|
||||
private = true
|
||||
script = [
|
||||
"""
|
||||
cd rust-lib/
|
||||
rustup show
|
||||
echo cargo build --package=dart-ffi --target ${TEST_COMPILE_TARGET} --features "${FEATURES}"
|
||||
cargo build --package=dart-ffi --target ${TEST_COMPILE_TARGET} --features "${FEATURES}"
|
||||
cd ../
|
||||
""",
|
||||
]
|
||||
script_runner = "@shell"
|
||||
|
||||
[tasks.copy-to-sandbox-folder]
|
||||
mac_alias = "copy-to-sandbox-folder-default"
|
||||
windows_alias = "copy-to-sandbox-folder-windows"
|
||||
linux_alias = "copy-to-sandbox-folder-default"
|
||||
|
||||
[tasks.copy-to-sandbox-folder-windows]
|
||||
private = true
|
||||
script = [
|
||||
"""
|
||||
# Copy the flowy_sdk lib to system temp directory for flutter unit test.
|
||||
lib = set ${LIB_NAME}.${TEST_LIB_EXT}
|
||||
dest = set ${CARGO_MAKE_WORKSPACE_WORKING_DIRECTORY}/app_flowy/.sandbox/${lib}
|
||||
rm ${dest}
|
||||
cp ${CARGO_MAKE_WORKSPACE_WORKING_DIRECTORY}/rust-lib/target/${TEST_COMPILE_TARGET}/${TEST_BUILD_FLAG}/${lib} \
|
||||
${dest}
|
||||
""",
|
||||
]
|
||||
script_runner = "@duckscript"
|
||||
|
||||
[tasks.copy-to-sandbox-folder-default]
|
||||
private = true
|
||||
script = [
|
||||
"""
|
||||
|
@ -1,5 +1,23 @@
|
||||
|
||||
[tasks.dart_unit_test]
|
||||
[tasks.dart_unit_test.macos]
|
||||
description = "Run flutter unit tests"
|
||||
script = '''
|
||||
cargo make --profile test-macos dart_unit_test_inner
|
||||
'''
|
||||
|
||||
[tasks.dart_unit_test.linux]
|
||||
description = "Run flutter unit tests"
|
||||
script = '''
|
||||
cargo make --profile test-linux dart_unit_test_inner
|
||||
'''
|
||||
|
||||
[tasks.dart_unit_test.windows]
|
||||
description = "Run flutter unit tests"
|
||||
script = '''
|
||||
cargo make --profile test-windows dart_unit_test_inner
|
||||
'''
|
||||
|
||||
[tasks.dart_unit_test_inner]
|
||||
dependencies = ["build-test-lib"]
|
||||
description = "Run flutter unit tests"
|
||||
script = '''
|
||||
|
Reference in New Issue
Block a user