Files
openidea/generators/scala.toml
T
l0ng-ai 605d5f4985 feat(new-project): project generators for mainstream languages and frameworks (#2689)
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
2026-11-11 17:22:57 +08:00

53 lines
807 B
TOML

id = "scala"
name = "Scala"
group = "Scala"
icon = "project-scala"
description = "A Scala 3 application built with sbt."
[[fields]]
id = "jdk"
label = "JDK:"
type = "sdk"
sdk = "jdk"
[[files]]
path = "build.sbt"
content = '''
val scala3Version = "3.7.3"
lazy val root = project
.in(file("."))
.settings(
name := "{{name|kebab}}",
version := "0.1.0-SNAPSHOT",
scalaVersion := scala3Version,
libraryDependencies += "org.scalameta" %% "munit" % "1.2.1" % Test
)
'''
[[files]]
path = "project/build.properties"
content = '''
sbt.version=1.11.7
'''
[[files]]
path = "src/main/scala/Main.scala"
content = '''
@main def hello(): Unit =
println("Hello, World!")
'''
[[files]]
path = ".gitignore"
content = '''
target/
.bsp/
.metals/
.bloop/
.idea/
'''
[settings.java]
jdk = "{{jdk}}"