setup, init, update, and version¶
asksh setup [--config path]¶
Runs the interactive configuration wizard and writes config.toml atomically with 0600 permissions.
| Flag | Type | Description |
|---|---|---|
--config |
string |
Destination path for config.toml (defaults to ~/.config/asksh/config.toml or $ASKSH_CONFIG_DIR/config.toml) |
Built-in provider presets¶
| Preset | Base URL | Default env var | Notes |
|---|---|---|---|
OpenRouter |
https://openrouter.ai/api/v1 |
OPENROUTER_API_KEY |
Fetches models from GET /models |
OpenCode Go |
https://opencode.ai/inference/go/openai/v1 |
OPENCODE_API_KEY |
Filters out *-free entries |
OpenCode Zen |
https://opencode.ai/inference/openai/v1 |
OPENCODE_API_KEY |
Filters out *-free entries |
DeepSeek |
https://api.deepseek.com/v1 |
DEEPSEEK_API_KEY |
Uses static presets deepseek-flash and deepseek-4-pro |
Ollama (local) |
http://localhost:11434/v1 |
None | Skips API key configuration by default |
Custom URL |
Prompted | OPENAI_API_KEY |
Accepts any http:// or https:// endpoint |
On the review screen, press t to test endpoint reachability (GET /models, falling back on HTTP 404/405 to POST /chat/completions with max_tokens: 1, 10-second timeout).
After saving, asksh setup prints the shell hook line for your shell unless ASKSH_FROM_INSTALLER is set.
asksh init <zsh|bash|fish>¶
Prints the shell integration script for zsh, bash, or fish to stdout.
zsh:eval "$(asksh init zsh)"bash:eval "$(asksh init bash)"(keybindings require Bash 4.0+)fish:asksh init fish | source
See Shell integration for details on keybindings and command recording hooks.
asksh update¶
Alias: asksh upgrade.
Checks https://github.com/askshell/asksh/releases/latest (via HTTP redirect, avoiding GitHub API rate limits), downloads the release archive and checksums.txt, verifies the SHA-256 digest, and atomically replaces the current asksh executable. On macOS running under Rosetta, it selects the arm64 archive.
Background update checks in the TUI cache results for 24 hours in ~/.local/share/asksh/update.json. Set ASKSH_NO_UPDATE_CHECK=1 to disable background checks.
asksh version¶
Aliases: --version, -V.
Prints the installed asksh version string (for example asksh 0.2.1).