junegunn/fzf · error
unsupported style preset: %s
Error message
unsupported style preset: %s
What it means
applyPreset only accepts the built-in style preset names (default, minimal, etc.) or a composite 'full[:border]' value. Any other string falls into the default case, where a SplitN on ':' must yield tokens[0] == "full", otherwise 'unsupported style preset: <preset>' is returned at options.go:3577.
Source
Thrown at src/options.go:3577
case "minimal":
opts.ListBorderShape = tui.BorderUndefined
opts.InputBorderShape = tui.BorderUndefined
opts.HeaderBorderShape = tui.BorderUndefined
opts.FooterBorderShape = tui.BorderLine
opts.Preview.border = tui.BorderLine
opts.Preview.info = false
opts.InfoStyle = infoDefault
opts.Theme.Gutter = tui.NewColorAttr()
space := " "
opts.Gutter = &space
empty := ""
opts.Separator = &empty
opts.Scrollbar = &empty
opts.CursorLine = false
default:
tokens := strings.SplitN(preset, ":", 2)
if tokens[0] != "full" {
return errors.New("unsupported style preset: " + preset)
}
if len(tokens) == 2 && len(tokens[1]) > 0 {
var err error
defaultBorderShape, err = parseBorder(tokens[1], false)
if err != nil {
return err
}
}
if defaultBorderShape != tui.BorderLine {
opts.ListBorderShape = defaultBorderShape
}
opts.InputBorderShape = defaultBorderShape
opts.HeaderBorderShape = defaultBorderShape
opts.FooterBorderShape = defaultBorderShape
opts.Preview.border = defaultBorderShape
if defaultBorderShape == tui.BorderLine {
opts.BorderShape = defaultBorderShapeView on GitHub (pinned to bd4efa277b)
Solutions
- Use a supported preset name or the 'full[:border]' form
- Check fzf --help for the list of valid presets
- Verify spelling and the colon separator (e.g. --style=full:rounded)
Example fix
# before fzf --style=compact # after fzf --style=full:rounded
Defensive patterns
Strategy: validation
Validate before calling
// Shell: whitelist presets presets='default minimal full' case "$style" in default|minimal|full|full:*) ;; *) style='default' ;; esac exec fzf --style="$style"
Prevention
- Only use documented preset names or the 'full[:border]' composite
- Validate style strings against a whitelist in shared config loaders
- Watch the colon syntax for border variants (--style=full:rounded)
When it happens
Trigger: Passing --style with an unknown name, e.g. --style=compact or --style=fullx, or misspelling 'full' (e.g. --style=ful:rounded). tokens[0] != "full" triggers the error.
Common situations: Typos in preset names; expecting presets from other tools or older/newer fzf versions; forgetting that the colon-border suffix only applies to the 'full' preset.
Related errors
- unknown option: %s
- unexpected value for %s: %s
- at least one of 'file' or 'dir' should be specified
- unable to put non-printable character
- unknown action: ${spec}
AI-assisted analysis of junegunn/fzf@bd4efa277b (2026-08-15).
Data as JSON: /api/errors/6bea023d2409d31d.
Report an issue: GitHub.