Synopsis

sc config [-hV] [--dir] [--file] [-g=KEY] [-s=KEY=VALUE]…​ [-u=KEY]…​ [COMMAND]

Description

Manage configuration settings for the sc CLI. The configuration system supports hierarchical configuration loading: 1. Command line options (highest priority) 2. Configuration file at $HOME/.sc/config 3. Default values (lowest priority)

Configuration File Location: - $HOME/.sc/config - $SC_CONFIG_DIR/config

Examples: sc config init # Initialize config file sc config --get providers.ollama.model # Get a specific setting sc config --set providers.ollama.model=llama3.2 # Set a configuration value sc config --file # Show config file path sc config --dir # Show config directory

Usage Examples

Initialize Configuration

Set up initial configuration with defaults:

sc config init

View Configuration

Display current configuration values:

sc config --get provider
sc config --get providers.ollama.model
sc config --file

Set Configuration Values

Configure Ollama settings:

sc config --set provider=ollama
sc config --set providers.ollama.model=llama3.2
sc config --set providers.ollama.base-url=http://localhost:11434

Configuration File

The configuration file is located at $HOME/.sc/config and uses a hierarchical key-value format:

provider: ollama
providers:
  ollama:
    base-url: http://localhost:11434
    model: llama3.2
chat-memory:
  jdbc:
    url: jdbc:hsqldb:mem:testdb

Common Settings

provider

The AI provider to use (default: ollama)

providers.ollama.model

Default model for Ollama (e.g., llama3.2, codellama, mistral)

providers.ollama.base-url

Ollama server endpoint (default: http://localhost:11434)

Options

--dir

Display the configuration directory path.

Shows where configuration files are stored.

--file

Display the configuration file path.

Shows the location of the active configuration file.

-g, --get=KEY

Get configuration value for the specified key.

Supports dot notation for nested properties.

Example: sc config --get providers.ollama.model

-h, --help

Show this help message and exit.

-s, --set=KEY=VALUE

Set configuration key to value.

Creates configuration file if it doesn’t exist.

Use dot notation for nested properties.

Examples: sc config --set providers.ollama.model=llama3.2 --set provider=ollama

-u, --unset=KEY

Remove configuration key and its value.

Supports multiple keys separated by spaces.

Example: sc config --unset providers.ollama.model --unset provider

-V, --version

Print version information and exit.

Commands

init

Initialize the configuration file with default settings.

See Also

sc(1), sc-chat(1), sc-rag(1)