{"record":{"id":"edc659349d2faa0c","repo":"kovidgoyal/kitty","slug":"unknown-kitten-option-s","errorCode":null,"errorMessage":"Unknown --kitten option: %s","messagePattern":"Unknown --kitten option: (.+?)","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"kittens/hyperlinked_grep/main.go","lineNumber":137,"sourceCode":"\t\t\t} else {\n\t\t\t\tsanitized_args = append(sanitized_args, \"--\"+key, val)\n\t\t\t}\n\t\t}\n\t\tswitch key {\n\t\tcase \"path-separator\":\n\t\t\tif val != string(os.PathSeparator) {\n\t\t\t\tdelegate_to_rg = true\n\t\t\t}\n\t\tcase \"context-separator\":\n\t\t\tcontext_separator = val\n\t\tcase \"field-context-separator\":\n\t\t\tfield_context_separator = val\n\t\tcase \"field-match-separator\":\n\t\t\tfield_match_separator = val\n\t\tcase \"kitten\":\n\t\t\tk, v, found := strings.Cut(val, \"=\")\n\t\t\tif !found || k != \"hyperlink\" {\n\t\t\t\treturn fmt.Errorf(\"Unknown --kitten option: %s\", val)\n\t\t\t}\n\t\t\tfor x := range strings.SplitSeq(v, \",\") {\n\t\t\t\tswitch x {\n\t\t\t\tcase \"none\":\n\t\t\t\t\tkitten_opts.context_lines = false\n\t\t\t\t\tkitten_opts.file_headers = false\n\t\t\t\t\tkitten_opts.matching_lines = false\n\t\t\t\tcase \"all\":\n\t\t\t\t\tkitten_opts.context_lines = true\n\t\t\t\t\tkitten_opts.file_headers = true\n\t\t\t\t\tkitten_opts.matching_lines = true\n\t\t\t\tcase \"matching_lines\":\n\t\t\t\t\tkitten_opts.matching_lines = true\n\t\t\t\tcase \"file_headers\":\n\t\t\t\t\tkitten_opts.file_headers = true\n\t\t\t\tcase \"context_lines\":\n\t\t\t\t\tkitten_opts.context_lines = true\n\t\t\t\tdefault:","sourceCodeStart":119,"sourceCodeEnd":155,"githubUrl":"https://github.com/kovidgoyal/kitty/blob/6d5d0c440603ad9bdf6dcd599f73f6dde21acb44/kittens/hyperlinked_grep/main.go#L119-L155","documentation":"The hyperlinked_grep kitten accepts --kitten hyperlink=... only; any other --kitten value (or a missing '=' key other than 'hyperlink') is rejected when parsing CLI args.","triggerScenarios":"Passing --kitten foo=bar or --kitten hyperlink without '=' — strings.Cut on '=' fails or key != 'hyperlink'.","commonSituations":"Copying a --kitten option from another kitten's docs; typos like --kitten hyperlinks=... or missing value.","solutions":["Use only --kitten hyperlink=<comma-list> (values: none, matching_lines, file_headers, context_lines)","Check spelling: key must be exactly 'hyperlink' with an '='","Remove the option if you don't need hyperlink customization"],"exampleFix":"# before\nkitty +kitten hyperlinked_grep --kitten hyperlinks=matching_lines foo\n# after\nkitty +kitten hyperlinked_grep --kitten hyperlink=matching_lines foo","handlingStrategy":"validation","validationCode":"k, v, ok := strings.Cut(val, \"=\")\nif !ok || k != \"hyperlink\" { return fmt.Errorf(\"bad --kitten value\") }","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Only --kitten hyperlink=<flags> is supported","Spell the key exactly 'hyperlink'"],"tags":["kitty","cli","argument-validation"],"backgroundTag":"invalid-cli-option","analyzedSha":"6d5d0c440603ad9bdf6dcd599f73f6dde21acb44","analyzedAt":"2026-08-27T14:20:20.142Z","schemaVersion":2},"datasetVersion":"2026-08-27T19:17:21.184Z"}