tari template init
Sets up an existing template crate for metadata generation.
tari template init [PATH] [OPTIONS]Arguments
Section titled “Arguments”| Argument | Description |
|---|---|
[PATH] | Path to the template crate directory (default: .) |
Options
Section titled “Options”| Option | Description |
|---|---|
--tags <TAGS> | Comma-separated tags (e.g. token,fungible,defi) |
--category <CATEGORY> | Template category (e.g. token, nft, defi) |
--documentation <URL> | Documentation URL |
--homepage <URL> | Homepage URL |
-y, --non-interactive | Skip interactive prompts, use only CLI args |
Examples
Section titled “Examples”Interactive mode
Section titled “Interactive mode”tari template init ./my-templatePrompts for tags, category, documentation, and homepage.
Non-interactive mode
Section titled “Non-interactive mode”tari template init ./my-template -y \ --tags token,fungible,defi \ --category token \ --documentation https://docs.example.com \ --homepage https://example.comWhat it does
Section titled “What it does”- Adds
tari_ootle_template_buildto[build-dependencies]inCargo.toml - Creates
build.rswithTemplateMetadataBuilder(or warns ifbuild.rsalready exists) - Writes
[package.metadata.tari-template]section with the provided metadata fields
The command is idempotent — running it twice will not duplicate entries.