( ´∀`)文字 Moji
Reference

Configuration reference

YAML fields, paths, environment variables, and precedence.

Paths

The default configuration path is ~/.moji/config.yaml. Override it with MOJI_CONFIG.

The default cache path is $XDG_CACHE_HOME/moji when XDG_CACHE_HOME is set, or ~/.cache/moji otherwise.

Complete example

download_dir: ~/Downloads/moji
github_token: ""
search_timeout_seconds: 15
cache_ttl_seconds: 3600
default_formats: [otf, ttf, woff2]

ranking:
  format: 3.0
  family_size: 2.0
  trusted: 1.5
  size_penalty: 0.5
  weight_bonus: 2.0

rate_limits:
  github:
    timeout_seconds: 15
    retries: 2
  getfonts:
    timeout_seconds: 15
    retries: 1
  websearch:
    timeout_seconds: 20
    retries: 0

providers:
  github:
    enabled: true
  getfonts:
    enabled: true
  websearch:
    enabled: false
    instance: ""

Fields

FieldTypeDefaultMeaning
download_dirstring~/Downloads/mojiDestination for get and TUI downloads
github_tokenstringemptyGitHub Code Search token
search_timeout_secondspositive integer15Overall search deadline
cache_ttl_secondsnon-negative integer3600Cache lifetime; 0 disables cache hits
default_formatsstring arrayOTF, TTF, WOFF2Formats used without --format
rankingmappingshown aboveRelative score weights
rate_limitsmappingshown abovePer-provider timeout and retry count
providersmappingshown aboveProvider enablement and optional instance

Environment variables

VariableMeaning
GITHUB_TOKENGitHub token; takes precedence over the config token
MOJI_CONFIGAlternate config path
XDG_CACHE_HOMEAlternate cache root
EDITORProgram used by moji config
NO_COLORDisable styled terminal output
TERM=dumbDisable styled terminal output

Per-invocation flags override general config defaults. Provider availability still depends on required credentials and instance settings.

On this page