---
title: "The CLI itself"
url: "https://docs.alisx.com/how-to/cli/"
---
# The CLI itself

Recipes for people and coding agents who already know the basics of the `alis` command line and have a goal.

- [Sign in and switch accounts](https://docs.alisx.com/how-to/cli/sign-in-and-switch-accounts.md): sign in, check who you are, and choose the account your Build usage is measured against.
- [Script the CLI with JSON](https://docs.alisx.com/how-to/cli/script-the-cli-with-json.md): parse one JSON object per command, read progress from stderr, branch on exit codes.
- [Run long operations asynchronously](https://docs.alisx.com/how-to/cli/run-long-operations-asynchronously.md): start with `--async`, re-attach with `alis operations wait`, inspect, cancel.
- [Work from another directory](https://docs.alisx.com/how-to/cli/work-from-another-directory.md): use `--cwd`, let the CLI resolve context, omit package IDs.
- [Keep the CLI up to date](https://docs.alisx.com/how-to/cli/keep-the-cli-up-to-date.md): `alis upgrade`, the TUI's automatic updates, and installing a specific version.
- [Enable shell completion](https://docs.alisx.com/how-to/cli/enable-shell-completion.md): bash, zsh, fish and PowerShell.
- [Ask questions across your platform](https://docs.alisx.com/how-to/cli/ask-questions-across-your-platform.md): cited answers from your sessions, conversations and skills.
- [Diagnose problems](https://docs.alisx.com/how-to/cli/diagnose-problems.md): `alis doctor`, what each exit code means, and the fix for the common errors.
