Every block and field of the elide.pkl project manifest.
amends "elide:project.pkl"
elide: resolves to the schema bundled with the running Elide; import "elide:Jvm.pkl" and the other modules work
the same way. To pin a schema version, amend the published URL instead:
pkl.elide.dev/1.6.0/project.pkl.
Patch releases within a MAJOR.MINOR line only add properties. A minor release can remove, rename or retype
properties and change defaults.
Pinned version
Result
Older than the running Elide
Uses that version’s definitions; a property removed since fails, naming the version.
Newer than the running Elide
Allowed; a property the running Elide lacks fails, naming the upgrade needed.
Another major version
Refused.
elide project export prints the evaluated manifest as JSON; elide build --inspect lists its tasks.
Project metadata
Property
Purpose
name, version, description
Project identity; version also names application archives.
build.flags holds the -f/--flag values; see Build Flags.
Engine contexts
engine { topology = "prespawn" contexts { spawn = "auto"; reserve = 2; min = 1; max = 16 }}
Property
Meaning
Default
topology
"prespawn", the only value.
"prespawn"
contexts.spawn
Context count: a positive integer, or "auto" (physical cores minus reserve, clamped).
1
contexts.reserve
Cores subtracted for "auto"; does not pin CPUs.
2
contexts.min, contexts.max
Bounds for any count.
1, none
maxContexts
Deprecated fixed count; cannot combine with contexts.
—
Each context evaluates the entry module once, with its own globals; all finish before the server is ready.
--contexts=N|auto on run, serve and dev overrides spawn. More than one context requires Linux.
Sources
sources { ["main"] = "lib/**/*.kt" ["integrationTest"] { type = "test" dependsOn { "main" } paths { "it/**/*.kt" } resources { "it/fixtures"; new { from = "it/config"; into = "META-INF" } } }}
packages, optionalPackages (named groups); elide install does not install them.
spring
version, starter, testStarter; expands into maven.
Value
Form
Maven entry
"group:artifact:version[:classifier]", a MavenPackageSpec (group, name, version, classifier or coordinate), a local JAR path, or a project reference.
Repository
A URL, or a spec with url, name, description, credentials (username, password, ntlmDomain, ntlmWorkstation).
substitutions key
group:artifact (any version) or group:artifact:version; the value is a file path.
A substitution keeps the coordinate’s resolution and transitive dependencies but puts the file on every classpath in
its place. Paths resolve against the declaring manifest; members inherit the root’s. A generated file needs its task
ordered first. Buckets and repositories: Dependencies.
"app" and "app.jar" both give app.jar; a SourceJar gives app-sources.jar.
WebImage
WebImage takes the NativeImage fields from, name, entrypoint, moduleName, dependsOn and options
(see Native Image), has no type, and adds:
Property
Values
Default
backend
"wasm-gc" (host GC) or "wasm-lm" (linear memory).
"wasm-gc"
runtime
"generic", "browser" or "node".
"generic"
autoRun
Start the program when the loader loads.
true
sourceMap
Emit a JavaScript source map.
false
entrypoint (or jvm.main) is required even with autoRun = false. Do not also pass raw flags for these four
settings. Guide: WebImage; flag-based artifacts:
migration.
Testing
import "elide:Testing.pkl" as Testingtesting { reports { Testing.xmlReport() } }
Property
Meaning
testing.reports
Report formats for every runner, written to .dev/reports/tests/<language>/<source-set>/; same as --reporter=junit.
Each member is a directory with its own elide.pkl; members cannot have members. elide init --template workspace
generates a root with a core library and an app that depends on it.
Behavior
Rule
Build scope
From the root, elide build/elide test cover every project; from a member, only that member.
Cross-project tasks
elide build core:compile-kotlin-main, or elide build core for its default tasks.
Shared state
Resolved dependencies and build state are stored in the root .dev; outputs stay in each project’s .dev.
Version pins
A member can omit a Maven version and take the root’s; a conflicting version is an error.
// core/elide.pklimport "elide:Jvm.pkl" as Jvmdependencies { maven { packages { "com.google.guava:guava" } // version from the root }}artifacts { ["jar"] = new Jvm.Jar { name = "core" }}