Skip to content

Nubo CLI

The nubo command is the main command-line interface for the Nubo language.

You can use it to run Nubo files directly or to execute CLI commands.

Terminal window
nubo <file|command> [flags]

You can also run subcommands:

Terminal window
nubo [command]

Running nubo without a file or command prints the help text and returns an error because at least one argument is required.

Error: requires at least 1 arg(s), only received 0
Terminal window
nubo <file|command> [flags]
nubo [command]

Pass a Nubo file path as the first argument.

Terminal window
nubo main.nubo

If the file does not exist, Nubo prints:

File does not exist

If the executed file returns a value, the CLI prints that value.

These flags are available on the root command.

FlagDescription
-d, --devRun the program in debug mode.
-h, --helpShow help.
--loglevel stringLanguage tokenizer and interpreter log level.
--nocolorDisable colorized output.
-v, --versionPrint the Nubo version.

Use --dev or -d to run in development/debug mode.

Terminal window
nubo main.nubo --dev

Short form:

Terminal window
nubo main.nubo -d

Internally, this sets the NUBO_DEV environment value for the process.

Use --nocolor to disable colorized terminal output.

Terminal window
nubo main.nubo --nocolor

Use --loglevel to control tokenizer and interpreter logging.

Terminal window
nubo main.nubo --loglevel debug

Use --version or -v to print the Nubo version.

Terminal window
nubo --version
CommandDescription
completionGenerate the autocompletion script for the specified shell.
configPrint the current configuration file path and parsed configuration.
delDelete a package from the current project.
downloadDownload all dependencies.
formatFormat Nubo files for better readability.
getAdd a package to the current project from a remote host.
helpHelp about any command.
initInitialize a Nubo package.
plugInitialize a Nubo plugin.
preparePrepare Nubo files for faster execution.
serveStart an HTTP server to serve Nubo files.

Every command supports --help.

Terminal window
nubo serve --help

General help:

Terminal window
nubo help

You can also ask for help about a specific command:

Terminal window
nubo help serve