Anesis is a Rust CLI for scaffolding JavaScript and TypeScript projects from remote Anesis templates and extending them with project addons.
It supports:
- creating a new project from a template
- checking cached templates and addons for updates before use
- authenticating against the Anesis service
- publishing GitHub repositories as Anesis templates
- installing cached addons and running addon commands inside a project
- upgrading the CLI from GitHub Releases with
anesis upgrade - notifying you when a newer Anesis version is available
The official Anesis website is anesis.vercel.app.
Use it as the main guide for learning and using Anesis:
- Docs cover installation, authentication, templates, addons, publishing, and reference material.
- Templates lists available project starters.
- Addons lists reusable workflow addons.
This README keeps a quick CLI reference for the repository and package users. The website contains the full, up-to-date usage guide.
Linux and macOS:
curl -sSL https://raw.githubusercontent.com/anesis-dev/anesis/main/install.sh | bashWindows PowerShell:
irm https://raw.githubusercontent.com/anesis-dev/anesis/main/install.ps1 | iexUnix installers place the anesis binary in ~/.local/bin. Cargo installs it in ~/.cargo/bin. Make sure the relevant directory is in your PATH.
npm install -g anesis-cliThe npm package downloads the matching prebuilt Anesis binary during postinstall.
cargo install anesisDownload the latest release artifact for your platform:
Most remote operations require authentication first:
anesis loginCreate a new project from a template:
anesis new my-app react-vite-tsAnesis checks whether the cached template is current before generating the project. If a newer template version exists, it updates the local cache first.
Top-level commands:
anesis new <NAME> <TEMPLATE_NAME>
anesis template <COMMAND>
anesis login
anesis logout
anesis account
anesis addon <COMMAND>
anesis upgrade
anesis completions <SHELL>
anesis use <ADDON_ID> <COMMAND>
Template management:
anesis template install <TEMPLATE_NAME>
anesis template list
anesis template remove <TEMPLATE_NAME>
anesis template publish <GITHUB_REPOSITORY_URL>
anesis template update <GITHUB_REPOSITORY_URL>
Addon management:
anesis addon install <ADDON_ID>
anesis addon list
anesis addon remove <ADDON_ID>
anesis addon publish <GITHUB_REPOSITORY_URL>
anesis addon update <GITHUB_REPOSITORY_URL>
Addon execution:
anesis use <ADDON_ID> <COMMAND>
Example:
anesis addon install drizzle
cd my-app
anesis use drizzle initUpgrade Anesis itself:
anesis upgradeInstall shell completions:
anesis completions zshSupported shells are bash, zsh, fish, and powershell.
Aliases:
anesis n ...foranesis new ...anesis t ...foranesis template ...anesis a ...foranesis addon ...anesis inforanesis loginanesis outforanesis logout
Install or refresh a template in the local cache:
anesis template install react-vite-tsWhen you run anesis new, Anesis also refreshes the template cache automatically if a newer version is available.
List cached templates:
anesis template listRemove a cached template:
anesis template remove react-vite-tsShow the authenticated account:
anesis accountPublish a GitHub repository as a template:
anesis template publish https://github.com/owner/repoUpdate a published template:
anesis template update https://github.com/owner/repoInstall an addon:
anesis addon install drizzleRun an installed addon command:
anesis use drizzle initWhen you run an addon command such as anesis use drizzle init, Anesis checks for a newer cached addon version first. If the add-on updated and the command is marked once: true, Anesis prompts you to re-run it.
List installed addons:
anesis addon listRemove a cached addon:
anesis addon remove drizzlePublish a GitHub repository as an addon:
anesis addon publish https://github.com/owner/repoUpdate a published addon:
anesis addon update https://github.com/owner/repoUpgrade the CLI to the latest release:
anesis upgradeAfter most commands, Anesis performs a background version check and prints a short upgrade notice when a newer CLI release is available.
Install shell completions:
anesis completions zshSupported shells are bash, zsh, fish, and powershell.
Anesis stores local state under ~/.anesis/:
- cached templates in
~/.anesis/cache/templates - cached addons in
~/.anesis/cache/addons - template cache index in
~/.anesis/cache/templates/anesis-templates.json - addon cache index in
~/.anesis/cache/addons/anesis-addons.json - CLI version-check cache in
~/.anesis/version_check.json - authentication data in
~/.anesis/auth.json
When addon commands run inside a project, Anesis records execution state in anesis.lock in the project root, including the add-on version used for each executed command.
Published templates are expected to include an anesis.template.json manifest in the template root. Anesis uses that manifest to track template metadata such as template name, version, and source repository.
Template files ending with .tera are rendered during project generation and written without the .tera suffix.
Available template variables:
project_nameproject_name_kebabproject_name_snake
Installed addons are expected to include an anesis.addon.json manifest. Anesis uses addon manifests to define:
- user inputs
- project detection rules
- command variants
- file modification steps such as create, copy, inject, replace, append, delete, rename, and move
Licensed under either of these:
- MIT license (LICENSE-MIT)
- Apache License 2.0 (LICENSE-Apache)