@@ -23,49 +23,56 @@ func init() {
2323 carapace .Gen (rootCmd ).Standalone ()
2424
2525 rootCmd .Flags ().Bool ("acknowledgements" , false , "Show acknowledgements" )
26- rootCmd .Flags ().Bool ( "cache-dir " , false , "Show bat's cache directory " )
26+ rootCmd .Flags ().String ( "binary " , "" , "How to treat binary content " )
2727 rootCmd .Flags ().BoolP ("chop-long-lines" , "S" , false , "Truncate all lines longer than screen width" )
2828 rootCmd .Flags ().String ("color" , "" , "When to use colors" )
29- rootCmd .Flags ().Bool ("config-dir" , false , "Show bat's configuration directory" )
30- rootCmd .Flags ().Bool ("config-file" , false , "Show path to the configuration file" )
29+ rootCmd .Flags ().String ("completion" , "" , "Show shell completion for a certain shell" )
3130 rootCmd .Flags ().String ("decorations" , "" , "When to show the decorations" )
3231 rootCmd .Flags ().Bool ("diagnostic" , false , "Show diagnostic information for bug reports" )
32+ rootCmd .Flags ().Bool ("diagnostics" , false , "Show diagnostic information for bug reports" )
3333 rootCmd .Flags ().BoolP ("diff" , "d" , false , "Only show lines that have been added/removed/modified" )
3434 rootCmd .Flags ().String ("diff-context" , "" , "Include N lines of context around added/removed/modified" )
3535 rootCmd .Flags ().StringSlice ("file-name" , nil , "Specify the name to display for a file" )
3636 rootCmd .Flags ().BoolP ("force-colorization" , "f" , false , "Alias for '--decorations=always --color=always'" )
37- rootCmd .Flags ().Bool ("generate-config-file" , false , "Generates a default configuration file" )
3837 rootCmd .Flags ().BoolP ("help" , "h" , false , "Print help" )
3938 rootCmd .Flags ().StringSliceP ("highlight-line" , "H" , nil , "Highlight lines N through M" )
40- rootCmd .Flags ().StringSlice ("ignored-suffix" , nil , "Ignore extension" )
39+ rootCmd .Flags ().StringSlice ("ignored-suffix" , nil , "Ignore extension. For example: " )
4140 rootCmd .Flags ().String ("italic-text" , "" , "Use italics in output" )
4241 rootCmd .Flags ().StringP ("language" , "l" , "" , "Set the language for syntax highlighting" )
43- rootCmd .Flags ().Bool ("lessopen" , false , "Enable the $LESSOPEN preprocessor" )
4442 rootCmd .Flags ().StringSliceP ("line-range" , "r" , nil , "Only print the lines from N to M" )
4543 rootCmd .Flags ().BoolP ("list-languages" , "L" , false , "Display all supported languages" )
4644 rootCmd .Flags ().Bool ("list-themes" , false , "Display all supported highlighting themes" )
4745 rootCmd .Flags ().StringSliceP ("map-syntax" , "m" , nil , "Use the specified syntax for files matching the glob pattern" )
48- rootCmd .Flags ().Bool ("no-config" , false , "Do not use the configuration file" )
49- rootCmd .Flags ().Bool ("no-custom-assets" , false , "Do not load custom assets" )
50- rootCmd .Flags ().Bool ("no-lessopen" , false , "Disable the $LESSOPEN preprocessor if enabled" )
51- rootCmd .Flags ().BoolP ("no-pager" , "" , false , "Disable paging" )
52- rootCmd .Flags ().BoolP ("no-paging" , "" , false , "Disable paging" )
5346 rootCmd .Flags ().String ("nonprintable-notation" , "" , "Set notation for non-printable characters" )
5447 rootCmd .Flags ().BoolP ("number" , "n" , false , "Show line numbers" )
5548 rootCmd .Flags ().String ("pager" , "" , "Determine which pager to use" )
5649 rootCmd .Flags ().String ("paging" , "" , "Specify when to use the pager, or use `-P` to disable" )
5750 rootCmd .Flags ().CountP ("plain" , "p" , "Show plain style" )
51+ rootCmd .Flags ().Bool ("set-terminal-title" , false , "Sets terminal title to filenames when using a pager" )
5852 rootCmd .Flags ().BoolP ("show-all" , "A" , false , "Show non-printable characters" )
59- rootCmd .Flags ().String ("style" , "" , "Comma-separated list of style elements to display" )
53+ rootCmd .Flags ().Bool ("show-nonprintable" , false , "Show non-printable characters" )
54+ rootCmd .Flags ().BoolP ("squeeze-blank" , "s" , false , "Squeeze consecutive empty lines" )
55+ rootCmd .Flags ().String ("squeeze-limit" , "" , "Set the maximum number of consecutive empty lines to be printed" )
56+ rootCmd .Flags ().String ("strip-ansi" , "" , "Strip colors from the input" )
57+ rootCmd .Flags ().StringSlice ("style" , nil , "Comma-separated list of style elements to display" )
6058 rootCmd .Flags ().String ("tabs" , "" , "Set the tab width to T spaces" )
61- rootCmd .Flags ().String ("terminal-width" , "" , "Explicitly set the width of the terminal" )
59+ rootCmd .Flags ().String ("terminal-width" , "" , "Explicitly set the width of the terminal instead of determining it automatically " )
6260 rootCmd .Flags ().String ("theme" , "" , "Set the color theme for syntax highlighting" )
61+ rootCmd .Flags ().String ("theme-dark" , "" , "Sets the color theme for syntax highlighting used for dark backgrounds" )
62+ rootCmd .Flags ().String ("theme-light" , "" , "Sets the color theme for syntax highlighting used for light backgrounds" )
6363 rootCmd .Flags ().BoolP ("unbuffered" , "u" , false , "This option exists for POSIX-compliance reasons" )
6464 rootCmd .Flags ().BoolP ("version" , "V" , false , "Print version" )
6565 rootCmd .Flags ().String ("wrap" , "" , "Specify the text-wrapping mode" )
66+ rootCmd .Flag ("diagnostics" ).Hidden = true
67+ rootCmd .Flag ("show-nonprintable" ).Hidden = true
6668
6769 carapace .Gen (rootCmd ).FlagCompletion (carapace.ActionMap {
70+ "binary" : carapace .ActionValuesDescribed (
71+ "no-printing" , "do not print any binary content" ,
72+ "as-text" , "treat binary content as normal text" ,
73+ ),
6874 "color" : carapace .ActionValues ("auto" , "never" , "always" ).StyleF (style .ForKeyword ),
75+ "completion" : carapace .ActionValues ("bash" , "fish" , "zsh" , "ps1" ),
6976 "decorations" : carapace .ActionValues ("auto" , "never" , "always" ).StyleF (style .ForKeyword ),
7077 "italic-text" : carapace .ActionValues ("never" , "always" ).StyleF (style .ForKeyword ),
7178 "language" : bat .ActionLanguages (),
@@ -81,11 +88,14 @@ func init() {
8188 "caret" , "Use character sequences like ˆG, ˆJ, ˆ@, .. to identify non-printable characters" ,
8289 "unicode" , "Use special Unicode code points to identify non-printable characters" ,
8390 ),
84- "pager" : bridge .ActionCarapaceBin ().Split (),
85- "paging" : carapace .ActionValues ("auto" , "never" , "always" ).StyleF (style .ForKeyword ),
86- "style" : bat .ActionStyles ().UniqueList ("," ),
87- "theme" : bat .ActionThemes (),
88- "wrap" : carapace .ActionValues ("auto" , "never" , "character" ),
91+ "pager" : bridge .ActionCarapaceBin ().Split (),
92+ "paging" : carapace .ActionValues ("auto" , "never" , "always" ).StyleF (style .ForKeyword ),
93+ "strip-ansi" : carapace .ActionValues ("auto" , "never" , "always" ).StyleF (style .ForKeyword ),
94+ "style" : bat .ActionStyles ().UniqueList ("," ),
95+ "theme" : bat .ActionThemes (),
96+ "theme-dark" : bat .ActionThemes (),
97+ "theme-light" : bat .ActionThemes (),
98+ "wrap" : carapace .ActionValues ("auto" , "never" , "character" ),
8999 })
90100
91101 carapace .Gen (rootCmd ).PositionalAnyCompletion (
0 commit comments