Skip to main content

Usage

dokrypt template <subcommand> [flags]

Subcommands

SubcommandDescription
listList available templates
infoShow template details
pullDownload a template from marketplace
pushPublish a template to marketplace
createScaffold a new template

list

List all available templates (built-in and installed).
dokrypt template list

Example Output

Name         Version   Category   Price   Description
evm-basic    2.0.0     basic      free    Starter EVM environment with Counter and ERC-20
evm-token    2.0.0     token      free    Token toolkit: ERC-20, vesting, staking, multisig
evm-nft      2.0.0     nft        free    NFT collection with marketplace, royalties, and IPFS
evm-dao      2.0.0     dao        free    DAO governance: governor, timelock, treasury, voting
evm-defi     2.0.0     defi       free    Full DeFi stack: AMM, lending vault, staking, oracle

info

Show detailed information about a template.
dokrypt template info <name>
Displays: name, version, description, author, category, difficulty, tags, chains, services, and license.

Examples

dokrypt template info evm-defi

pull

Download a template from the marketplace.
dokrypt template pull <name>
If the template is built-in, the download is skipped. Otherwise, downloads from the marketplace registry and installs to ~/.dokrypt/templates/.

Examples

dokrypt template pull uniswap-v3

push

Publish the current directory as a template to the marketplace.
dokrypt template push
Requires a template.yaml in the current directory and the DOKRYPT_REGISTRY_TOKEN environment variable.

Examples

cd my-template
DOKRYPT_REGISTRY_TOKEN=xxx dokrypt template push

create

Scaffold a new template directory with boilerplate files.
dokrypt template create <name>

Created Files

FileDescription
template.yamlTemplate metadata (name, version, description, author, tags, chains, services, license)
dokrypt.yaml.tmplConfiguration template with {{ .ProjectName }} placeholder

Example

dokrypt template create my-defi-template
Creates:
my-defi-template
template.yaml
dokrypt.yaml.tmpl

template.yaml format

name: my-defi-template
version: "0.1.0"
description: "Your template description"
author: your-name
category: defi
difficulty: intermediate
tags: [defi, ethereum]
chains: [ethereum]
services: []
license: MIT

Template Variables

Templates use Go’s text/template syntax. Available variables:
VariableDescriptionExample
{{ .ProjectName }}User’s project namemy-dapp
{{ .ChainName }}Blockchain nameethereum
{{ .ChainID }}Chain ID31337
{{ .Engine }}Node engineanvil
{{ .Author }}Project authordev
Files ending in .tmpl are rendered through the template engine and the .tmpl extension is removed. All other files are copied as-is.