silk.build.manifest.
Package identities, fetch pins, and publication settings read from silk.toml.
Import as Manifest with import silk.build.manifest { Manifest }.
Public declarations: 21.
Manifest#
pub struct ManifestStatic package and workspace data. Compilation settings belong to the build graph.
Field package#
pub package: Option<Package>The package at this directory, when it is not a virtual workspace.
Field dependencies#
pub dependencies: Dictionary<Dependency>Packages this package may import, keyed by their import aliases.
Field workspace#
pub workspace: Option<Workspace>Workspace membership and shared dependency pins.
Field native#
pub native: Option<Native>Downloaded native archives and local replacements.
Field component#
pub component: Option<Component>The package's WebAssembly component interface and world.
Field unstable#
pub unstable: Option<Unstable>Runtime composition declarations that travel with the package.
Field pack#
pub pack: Option<Pack>Source and binary archive publication settings.
Field release#
pub release: Option<Release>Release publication settings.
Field postInit#
pub postInit: Option<List<PostInit>>Commands run only when a developer initializes a project from this template.
Field tool#
pub tool: Option<Tool>Input-only configuration owned by external tools; manifest edits preserve its original TOML.
Implementation Schema for Manifest#
impl Schema for ManifestOperation spec#
static fn spec() -> Spec<Manifest>Operation check#
fn check(self: &Self, checks: &mut Checks<Self>) -> ()Tool#
pub struct ToolAn external tool's table, accepted without interpreting its keys or values. Decoding discards its contents; a manifest editor must preserve the source document.
Implementation Schema for Tool#
impl Schema for ToolComponent#
pub struct ComponentThe interface definition and exported world of a WebAssembly component package.
Field wit#
pub wit: StringA WIT file or directory relative to this package.
Field world#
pub world: StringThe WIT world to compile.
Implementation Schema for Component#
impl Schema for ComponentOperation spec#
static fn spec() -> Spec<Component>Unstable#
pub struct UnstableExperimental package declarations whose selected bindings become explicit request inputs.
Field composition#
pub composition: Option<Composition>Runtime implementations, defaults, and execution-storage bindings.
Implementation Schema for Unstable#
impl Schema for UnstableOperation spec#
static fn spec() -> Spec<Unstable>Composition#
pub struct CompositionRuntime and provider declarations available to compilations of this package.
Field runtimes#
pub runtimes: Option<List<Runtime>>Named runtime modules declared by the package.
Field defaults#
pub defaults: Option<List<String>>The runtime names selected by default.
Field components#
pub components: Option<List<Capability>>Execution-storage implementations.
Field retention#
pub retention: Option<List<Retention>>Declarations retained regardless of import reachability.
Field requirements#
pub requirements: Option<List<String>>Reserved requirements; the current compiler accepts only an empty list.
Implementation Schema for Composition#
impl Schema for CompositionOperation spec#
static fn spec() -> Spec<Composition>Operation check#
fn check(self: &Self, checks: &mut Checks<Self>) -> ()Runtime#
pub struct RuntimeA named package runtime module.
Field name#
pub name: StringThe name a compilation selects.
Field module#
pub module: StringThe module implementing the runtime.
Implementation Schema for Runtime#
impl Schema for RuntimeOperation spec#
static fn spec() -> Spec<Runtime>Capability#
pub struct CapabilityA runtime capability supplied by a complete set of declaration bindings.
Field capability#
pub capability: StringThe supported capability, execution-storage.
Field bindings#
pub bindings: List<StorageBinding>One binding for each execution-storage operation.
Implementation Schema for Capability#
impl Schema for CapabilityOperation spec#
static fn spec() -> Spec<Capability>Operation check#
fn check(self: &Self, checks: &mut Checks<Self>) -> ()StorageBinding#
pub struct StorageBindingOne operation supplied by an execution-storage implementation.
Field operation#
pub operation: StringThe operation: create, acquire, release, or destroy.
Field module#
pub module: StringThe module declaring the implementation.
Field declaration#
pub declaration: StringThe implementation's declaration name.
Implementation Schema for StorageBinding#
impl Schema for StorageBindingOperation spec#
static fn spec() -> Spec<StorageBinding>Retention#
pub struct RetentionA declaration kept even when no ordinary source import reaches it.
Field module#
pub module: StringThe module declaring the retained value or function.
Field declaration#
pub declaration: StringThe declaration name.
Implementation Schema for Retention#
impl Schema for RetentionOperation spec#
static fn spec() -> Spec<Retention>Package#
pub struct PackageA package identity and its source and publication layout.
Field name#
pub name: StringThe lowercase package name, distinct from its local import aliases.
Field version#
pub version: StringThe full semantic version; absent versions are 0.0.0.
Field silkVersion#
pub silkVersion: Option<String>The compiler version selected by the launcher.
Field source#
pub source: StringThe module root, resolved relative to the package directory.
Field main#
pub main: Option<String>The root module relative to source; absent roots use main.silk or lib.silk.
Field kind#
pub kind: StringWhether the default command builds an executable or checks a library.
Field exports#
pub exports: Option<List<String>>Canonical module names that other packages may import.
Field description#
pub description: Option<String>The package description.
Field license#
pub license: Option<String>The license identifier.
Field repository#
pub repository: Option<String>The source repository URL.
Field homepage#
pub homepage: Option<String>The project website URL.
Field authors#
pub authors: Option<List<String>>Author names.
Field keywords#
pub keywords: Option<List<String>>Discovery keywords.
Field readme#
pub readme: Option<String>The README path relative to the package directory.
Field include#
pub include: Option<List<String>>Additional packaged files and directories, also available through Package.path.
Field publish#
pub publish: boolWhether this package may be published.
Implementation Schema for Package#
impl Schema for PackageOperation spec#
static fn spec() -> Spec<Package>Operation check#
fn check(self: &Self, checks: &mut Checks<Self>) -> ()Dependency#
pub struct DependencyOne path, pinned Git commit, pinned archive, or workspace catalog entry.
Field path#
pub path: Option<String>A local directory, or a subdirectory of the fetched repository or archive.
Field package#
pub package: Option<String>The selected package name when it differs from the import alias.
Field git#
pub git: Option<String>A Git repository URL.
Field rev#
pub rev: Option<String>A complete lowercase Git commit hash.
Field url#
pub url: Option<String>An HTTPS or local file archive URL.
Field sha256#
pub sha256: Option<String>The archive's lowercase SHA-256 digest.
Field workspace#
pub workspace: Option<bool>Selects the same alias from the enclosing workspace catalog.
Field tools#
pub tools: boolExplicitly authorizes this dependency's sandboxed build tools.
Implementation Schema for Dependency#
impl Schema for DependencyOperation spec#
static fn spec() -> Spec<Dependency>Operation check#
fn check(self: &Self, checks: &mut Checks<Self>) -> ()Workspace#
pub struct WorkspaceA workspace's member paths, output directory, and dependency catalog.
Field members#
pub members: List<String>Package directories or globs relative to this manifest.
Field outputDir#
pub outputDir: StringThe build output directory relative to the workspace root.
Field silkVersion#
pub silkVersion: Option<String>The compiler version selected for workspace members.
Field dependencies#
pub dependencies: Dictionary<Dependency>Fully specified dependency sources shared by workspace members.
Implementation Schema for Workspace#
impl Schema for WorkspaceOperation spec#
static fn spec() -> Spec<Workspace>Operation check#
fn check(self: &Self, checks: &mut Checks<Self>) -> ()Native#
pub struct NativeNative files fetched from pinned archives; compilation and linking are graph operations.
Field archive#
pub archive: Dictionary<Archive>Archives keyed by their package-local names.
Field overrides#
pub overrides: Dictionary<ArchiveOverride>Local archive replacements keyed by the same names.
Implementation Schema for Native#
impl Schema for NativeOperation spec#
static fn spec() -> Spec<Native>Archive#
pub struct ArchiveOne portable archive pin or a table of pins selected by target triple.
Field url#
pub url: Option<String>The portable archive URL, absent when using target-specific pins.
Field sha256#
pub sha256: Option<String>The portable archive digest.
Field strip#
pub strip: Option<u32>The number of directory components removed during extraction.
Field targets#
pub targets: Dictionary<ArchivePin>Target-specific archive pins.
Implementation Schema for Archive#
impl Schema for ArchiveOperation spec#
static fn spec() -> Spec<Archive>Operation check#
fn check(self: &Self, checks: &mut Checks<Self>) -> ()ArchivePin#
pub struct ArchivePinThe verified archive downloaded for one target.
Field url#
pub url: StringAn HTTPS or local file URL.
Field sha256#
pub sha256: StringThe SHA-256 digest of the downloaded bytes.
Field strip#
pub strip: u32Directory components removed during extraction.
Implementation Schema for ArchivePin#
impl Schema for ArchivePinOperation spec#
static fn spec() -> Spec<ArchivePin>ArchiveOverride#
pub struct ArchiveOverrideA developer's local replacement for a downloaded native archive.
Field path#
pub path: StringThe local installation directory.
Implementation Schema for ArchiveOverride#
impl Schema for ArchiveOverrideOperation spec#
static fn spec() -> Spec<ArchiveOverride>Pack#
pub struct PackOptional binary archives published beside the source archive.
Field binary#
pub binary: Option<Binary>Enables binary publication and configures its layout.
Implementation Schema for Pack#
impl Schema for PackOperation spec#
static fn spec() -> Spec<Pack>Binary#
pub struct BinaryDefault binary archive settings and target-specific overrides.
Field format#
pub format: StringArchive format: tar.gz or zip.
Field layout#
pub layout: StringExecutable placement: bin or flat.
Field include#
pub include: Option<List<String>>Additional paths copied into every binary archive.
Field target#
pub target: Dictionary<BinaryTarget>Settings that replace the defaults for each named target.
Implementation Schema for Binary#
impl Schema for BinaryOperation spec#
static fn spec() -> Spec<Binary>BinaryTarget#
pub struct BinaryTargetBinary archive settings replaced for one target; absent fields retain the defaults.
Field format#
pub format: Option<String>The replacement archive format.
Field layout#
pub layout: Option<String>The replacement executable placement.
Field include#
pub include: Option<List<String>>The replacement list of additional files.
Implementation Schema for BinaryTarget#
impl Schema for BinaryTargetOperation spec#
static fn spec() -> Spec<BinaryTarget>Release#
pub struct ReleaseRelease repository and version-source settings.
Field repository#
pub repository: Option<String>The GitHub repository as owner/name.
Field directory#
pub directory: Option<String>The release directory relative to the repository root.
Field versionFile#
pub versionFile: Option<String>A Silk version constant source file outside .changes.
Implementation Schema for Release#
impl Schema for ReleaseOperation spec#
static fn spec() -> Spec<Release>PostInit#
pub struct PostInitA template command run only by an explicit silk init invocation.
Field command#
pub command: List<String>The executable followed by its arguments.
Field arguments#
pub arguments: boolWhether to append arguments passed to silk init after --.
Implementation Schema for PostInit#
impl Schema for PostInitOperation spec#
static fn spec() -> Spec<PostInit>Profiles: aarch64-apple-darwin, aarch64-unknown-linux-gnu, aarch64-unknown-linux-gnu-no-libc, x86_64-unknown-linux-gnu, x86_64-unknown-linux-gnu-no-libc, wasm32-unknown-unknown, wasm32-wasip1, wasm32-wasip2, x86_64-pc-windows-msvc, wasm64-unknown-unknown.