Configuration
Configure Prompter CLI through TOML configuration files.
Configuration Files
Prompter searches for configuration in this order:
- Local config:
.prompter/config.toml(current directory) - Global config:
$XDG_CONFIG_HOME/prompter/config.toml
Local configuration overrides global configuration.
Creating Configuration
Initialize Config
prompter config initCreates ~/.config/prompter/config.toml with all options documented.
Edit Config
prompter configOpens your configuration file in your editor.
Configuration Options
Locations
# Where user templates are storedprompts_location = "$XDG_DATA_HOME/prompter/prompts"
# Where prompt history is savedhistory_location = "$XDG_CACHE_HOME/prompter/history"
# Where local (project) templates are storedlocal_prompts_location = "prompts"Environment variables are expanded:
$XDG_DATA_HOME- Usually~/.local/share$XDG_CONFIG_HOME- Usually~/.config$XDG_CACHE_HOME- Usually~/.cache$HOME- User home directory
Templates & Agents
# Include agent templates# Options: all, none, agents, claude, opencode, cursor, antigravity, kiroinclude_agents = "all"
# Editor commandeditor = "nvim"
# Directory inclusion strategy# Options: git (tracked files), filesystem (walk directory, uses .gitignore)directory_strategy = "git"Directory strategies:
git- Include only tracked files (respects git status)filesystem- Walk the directory tree (respects .gitignore)
CLI Behavior
# Start in interactive mode by defaultinteractive_default = true
# Show base prompt input field in interactive modeshow_base_prompt_input = true
# Use Alt+Enter to submit (instead of Ctrl+D)alt_enter_submit = false
# Include built-in shorthand flagsinclude_builtin_shorthand = trueOutput
# Default output target# Options: clipboard, stdout, file:/path, editortarget = "clipboard"Output targets:
clipboard- Copy to system clipboardstdout- Print to terminalfile:/path- Write to specified fileeditor- Open in your configured editor
History
# Automatic history cleanup# Options: never, 1, 7, 31 (days)history_clear_cycle = "never"
# History filename format# Options: month-day_eu, month-day_us, isohistory_file_format = "month-day_eu"
# Show relative time in history (e.g., "2 hours ago")history_enable_time_ago = true
# Date/time format for history# Options: "day, month", "month, day", "iso", or Go time layouthistory_date_time = "day, month"
# Disable history savingdisable_history = false
# Separator between prompt sections in historyprompt_separator = "---"Colors
Customize terminal colors using named colors, numeric values, or hex codes:
# Named colors: black, red, green, yellow, blue, magenta, cyan, white# Numeric: 0-255 (ANSI color codes)# Hex: "#ff8800"
headings = "15" # Bright whiteprimary = "02" # Greensecondary = "06" # Cyantext = "07" # Light graytext_highlight = "06" # Cyandescription_highlight = "05" # Magentatags = "13" # Bright magentaflags = "12" # Bright bluemuted = "08" # Dark graybase_prompt_badge = "06" # Cyanborder = "08" # Dark grayOptional color fallbacks:
accent- Used as a fallback for tagsbase_prompt- Used as a fallback for text
Flag Remapping
By default built-in shorthand flags in the root command are capitalized to prevent conflicts with genrated templates.
You can change the bulit-in shorthand flags to suit your needs.
You can set any flag shorthand to, a lowercase letter, a different uppercase letter, or remove it.
These flags only affect the root command prompter.
[remap_short_flags]# Built-in flags: A B D E F I T V Y# Example remappings:directory = "d" # Change -D to -dfile = "f" # Change -F to -fclipboard = "B" # Keep as -BComplete Example
# Locationsprompts_location = "$XDG_DATA_HOME/prompter/prompts"history_location = "$XDG_CACHE_HOME/prompter/history"local_prompts_location = "prompts"
# Templates & agentsinclude_agents = "all"editor = "nvim"directory_strategy = "git"
# CLI behaviorinteractive_default = trueshow_base_prompt_input = truealt_enter_submit = falseinclude_builtin_shorthand = true
# Outputtarget = "clipboard"
# Historyhistory_clear_cycle = "7"history_file_format = "month-day_eu"history_enable_time_ago = truehistory_date_time = "day, month"disable_history = falseprompt_separator = "---"
# Colorsheadings = "15"primary = "02"secondary = "06"text = "07"text_highlight = "06"description_highlight = "05"tags = "13"flags = "12"muted = "08"base_prompt_badge = "06"border = "08"
[remap_short_flags]directory = "d"Project-Specific Configuration
Create .prompter/config.toml in your project:
# Use project templateslocal_prompts_location = "prompts"
# Include agent templatesinclude_agents = "all"
# Project-specific editoreditor = "code"
# Output to file for CItarget = "file:/tmp/prompt.txt"Configuration Precedence
Configuration is merged in this order (later overrides earlier):
- Default values
- Global config (
~/.config/prompter/config.toml) - Local config (
.prompter/config.toml) - Environment variables
- Command-line flags