mirror of
https://github.com/l0ng-ai/openidea.git
synced 2026-11-14 16:07:52 +00:00
File › New Project offers 38 generators grouped by language (Java, Spring Boot, Quarkus, Micronaut, Kotlin, Ktor, Scala, Python/Django/FastAPI/Flask, Node/Vite/Next.js/Nuxt/Angular/SvelteKit/Astro/NestJS/Express, Go, Rust, C/C++, Zig, .NET, PHP/Laravel/Symfony, Ruby/Rails, Dart/Flutter, Swift, Elixir/Phoenix, Haskell, static website, empty). Each is a declaration in generators/<id>.toml run by the new ide-scaffold crate: built-in templates, the framework's official CLI run non-interactively, or a project service zip (Spring Initializr, code.quarkus.io, Micronaut Launch) whose metadata becomes form fields. Projects are built in a staging directory and moved into place only on success. The dialog renders each form from its schema, flags missing toolchains with install hints and streams progress; created projects open trusted. New Project is also on the welcome screen and the title bar project menu. Closes #709
63 lines
1.4 KiB
TOML
63 lines
1.4 KiB
TOML
id = "flutter"
|
|
name = "Flutter"
|
|
group = "Dart"
|
|
icon = "project-flutter"
|
|
order = 1
|
|
description = "A Flutter app, plugin or package from flutter create."
|
|
|
|
[[requires]]
|
|
program = "flutter"
|
|
hint = "Install Flutter: https://docs.flutter.dev/get-started/install"
|
|
|
|
[[fields]]
|
|
id = "template"
|
|
label = "Template:"
|
|
type = "choice"
|
|
segmented = true
|
|
options = [
|
|
{ value = "app", label = "Application" },
|
|
{ value = "package", label = "Package" },
|
|
{ value = "plugin", label = "Plugin" },
|
|
]
|
|
default = "app"
|
|
|
|
[[fields]]
|
|
id = "package"
|
|
label = "Package name:"
|
|
type = "text"
|
|
pattern = '^[a-z][a-z0-9_]*$'
|
|
default = "{{name|snake}}"
|
|
|
|
[[fields]]
|
|
id = "org"
|
|
label = "Organization:"
|
|
type = "text"
|
|
pattern = '^[A-Za-z_][\w]*(\.[A-Za-z_][\w]*)*$'
|
|
default = "com.example"
|
|
visible = { template = ["app", "plugin"] }
|
|
|
|
[[fields]]
|
|
id = "sample"
|
|
label = "Empty application"
|
|
type = "checkbox"
|
|
default = "false"
|
|
visible = { template = "app" }
|
|
hint = "Hello World instead of the counter sample."
|
|
|
|
[[steps]]
|
|
label = "Running flutter create"
|
|
program = "flutter"
|
|
args = [
|
|
"create", "--template", "{{template}}", "--project-name", "{{package}}", "--no-pub",
|
|
{ when = { template = ["app", "plugin"] }, args = ["--org", "{{org}}"] },
|
|
{ when = { template = "app", sample = "true" }, args = ["--empty"] },
|
|
".",
|
|
]
|
|
env = { FLUTTER_SUPPRESS_ANALYTICS = "true" }
|
|
|
|
[[after]]
|
|
label = "Running flutter pub get"
|
|
program = "flutter"
|
|
args = ["pub", "get"]
|
|
optional = true
|