Skip to content

Commands

Commands

This page documents the commands dispatched by the current drago/src/main.tg implementation.

Global flags

These flags are parsed before command dispatch and can be combined with multiple commands when they make sense.

FlagMeaning
--quietreduce user-facing progress output
--verboserequest more output from commands that support it
--lockedenforce lockfile consistency
--frozenenforce lockfile consistency and offline behavior
--offlinedisable network access for dependency resolution where supported
--yesauto-confirm commands that support confirmation
-p, --package <name>select one workspace member
--features <csv>enable named feature set
--all-featuresenable all manifest features
--no-default-featuresdisable the default feature
--git <url>use a git dependency source for add and install
--path <dir>use a local path dependency source for add and install
--alias <name>set the dependency name for --git or --path
--ref <ref>git ref for --git dependencies

Core commands

CommandDescription
drago new <name>scaffold a new package
drago buildbuild the current package or selected workspace member
drago runbuild and run one package
drago testrun package tests
drago checkcompile-check without a normal run step
drago fmtrun thagore-fmt
drago versionprint drago and thagc versions
drago helpprint usage

Dependency commands

CommandDescription
drago add <package> [version]add a registry dependency
drago add --git <url> [ref] --alias <name>add a git dependency
drago add --path <dir> [version] --alias <name>add a local path dependency
drago remove <package>remove one dependency
drago installinstall all dependencies from the manifest
drago install <package> [version]npm-style alias of add
drago updateupdate all dependencies
drago update <dependency>update one dependency
drago update dragoself-update drago
drago update thagcself-update thagc
drago update toolchainself-update the whole toolchain
drago update allsame intent as toolchain

Registry and inspection commands

CommandDescription
drago publishpublish the current package
drago cache listlist cache entries
drago cache sizeprint cache size
drago cache cleanclean cache files
drago cache purgeremove the cache completely
drago cache purge-unusedremove cache entries not referenced by lockfiles
drago auditaudit dependencies
drago treeprint a dependency tree
drago why <package>explain why a package is present
drago outdatedcheck for newer versions
drago runtime-path <package> [asset-dir]print cached runtime path for a dependency

Examples

Create a new project:

Terminal window
drago new demo

Build the current package:

Terminal window
drago build

Run one workspace member:

Terminal window
drago run --package app

Add a registry dependency:

Terminal window
drago add http 1.2.0

Add a local path dependency:

Terminal window
drago add --path ../shared --alias shared

Format the current project:

Terminal window
drago fmt