diff options
| author | Dan Davison <dandavison7@gmail.com> | 2022-01-16 15:43:02 -0500 |
|---|---|---|
| committer | Dan Davison <dandavison7@gmail.com> | 2022-01-16 16:44:13 -0500 |
| commit | 4fa97a60f400a58e7c27cf8be694cf65d3d67f6f (patch) | |
| tree | 1a6de406134dabe6f20d84dd45284cba49e95586 /src | |
| parent | 587453d12074d75483049270fbab834cac98e8ca (diff) | |
Sort options in --help output
Diffstat (limited to 'src')
| -rw-r--r-- | src/cli.rs | 1125 |
1 files changed, 562 insertions, 563 deletions
@@ -203,142 +203,119 @@ https://github.com/dandavison/delta/issues. " )] pub struct Opt { - #[clap(long = "light")] - /// Use default colors appropriate for a light terminal background. + #[clap(long = "blame-code-style", value_name = "STYLE_STRING")] + /// Style string for the code section of a git blame line. /// - /// For more control, see the style options and --syntax-theme. - pub light: bool, + /// By default the code will be syntax-highlighted with the same background color as the blame + /// format section of the line (the background color is determined by blame-palette). E.g. + /// setting this option to 'syntax' will syntax-highlight the code with no background color. + pub blame_code_style: Option<String>, - #[clap(long = "dark")] - /// Use default colors appropriate for a dark terminal background. + #[clap( + long = "blame-format", + default_value = "{timestamp:<15} {author:<15.14} {commit:<8}", + value_name = "FORMAT_STRING" + )] + /// Format string for git blame commit metadata. /// - /// For more control, see the style options and --syntax-theme. - pub dark: bool, + /// Available placeholders are "{timestamp}", "{author}", and "{commit}". + pub blame_format: String, - #[clap(short = 'n', long = "line-numbers")] - /// Display line numbers next to the diff. + #[clap(long = "blame-palette", value_name = "COLORS")] + /// Background colors used for git blame lines (space-separated string). /// - /// See LINE NUMBERS section. - pub line_numbers: bool, + /// Lines added by the same commit are painted with the same color; colors are recycled as + /// needed. + pub blame_palette: Option<String>, - #[clap(short = 's', long = "side-by-side")] - /// Display diffs in side-by-side layout. - pub side_by_side: bool, + #[clap( + long = "blame-separator", + default_value = "│", + value_name = "SEPARATOR_STRING" + )] + /// Separator between the commit metadata and code sections of a git blame line. + pub blame_separator: String, - #[clap(long = "diff-highlight")] - /// Emulate diff-highlight. - /// - /// (https://github.com/git/git/tree/master/contrib/diff-highlight) - pub diff_highlight: bool, + #[clap(long = "blame-separator-style", value_name = "STYLE_STRING")] + /// Style string for the separator between the commit metadata and code sections of a git blame line. + pub blame_separator_style: Option<String>, - #[clap(long = "diff-so-fancy")] - /// Emulate diff-so-fancy. - /// - /// (https://github.com/so-fancy/diff-so-fancy) - pub diff_so_fancy: bool, + #[clap( + long = "blame-timestamp-format", + default_value = "%Y-%m-%d %H:%M:%S %z", + value_name = "TIMESTAMP_FORMAT_STRING" + )] + /// Format of `git blame` timestamp in raw git output received by delta. + pub blame_timestamp_format: String, - #[clap(long = "navigate")] - /// Activate diff navigation. + #[clap(long = "color-only")] + /// Do not alter the input structurally in any way. /// - /// Use n to jump forwards and N to jump backwards. To change the file labels used see - /// --file-modified-label, --file-removed-label, --file-added-label, --file-renamed-label. - pub navigate: bool, + /// But color and highlight hunk lines according to your delta configuration. This is mainly + /// intended for other tools that use delta. + pub color_only: bool, - #[clap(long = "relative-paths")] - /// Output all file paths relative to the current directory. + #[clap( + long = "commit-decoration-style", + default_value = "", + value_name = "STYLE_STRING" + )] + /// Style string for the commit hash decoration. /// - /// This means that they will resolve correctly when clicked on or used in shell commands. - pub relative_paths: bool, + /// See STYLES section. The style string should contain one of the special attributes 'box', + /// 'ul' (underline), 'ol' (overline), or the combination 'ul ol'. + pub commit_decoration_style: String, - #[clap(long = "hyperlinks")] - /// Render commit hashes, file names, and line numbers as hyperlinks. - /// - /// Following the hyperlink spec for terminal emulators: - /// https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda. By default, file names - /// and line numbers link to the local file using a file URL, whereas commit hashes link to the - /// commit in GitHub, if the remote repository is hosted by GitHub. See - /// --hyperlinks-file-link-format for full control over the file URLs emitted. Hyperlinks are - /// supported by several common terminal emulators. To make them work, you must use less version - /// >= 581 with the -R flag (or use -r with older less versions, but this will break e.g. - /// --navigate). If you use tmux, then you will also need a patched fork of tmux (see - /// https://github.com/dandavison/tmux). - pub hyperlinks: bool, + #[clap(long = "commit-regex", default_value = r"^commit ")] + /// Regular expression used to identify the commit line when parsing git output. + pub commit_regex: String, - #[clap(long = "keep-plus-minus-markers")] - /// Prefix added/removed lines with a +/- character, as git does. + #[clap( + long = "commit-style", + default_value = "raw", + value_name = "STYLE_STRING" + )] + /// Style string for the commit hash line. /// - /// By default, delta does not emit any prefix, so code can be copied directly from delta's + /// See STYLES section. The style 'omit' can be used to remove the commit hash line from the /// output. - pub keep_plus_minus_markers: bool, - - #[clap(long = "show-config")] - /// Display the active values for all Delta options. - /// - /// Style string options are displayed with foreground and background colors. This can be used to - /// experiment with colors by combining this option with other options such as --minus-style, - /// --zero-style, --plus-style, --light, --dark, etc. - pub show_config: bool, - - #[clap(long = "list-languages")] - /// List supported languages and associated file extensions. - pub list_languages: bool, - - #[clap(long = "list-syntax-themes")] - /// List available syntax-highlighting color themes. - pub list_syntax_themes: bool, - - #[clap(long = "show-syntax-themes")] - /// Show example diff for available syntax-highlighting themes. - /// - /// If diff output is supplied on standard input then this will be used for the demo. For - /// example: `git show | delta --show-syntax-themes`. - pub show_syntax_themes: bool, - - #[clap(long = "show-themes")] - /// Show example diff for available delta themes. - /// - /// A delta theme is a delta named feature (see --features) that sets either `light` or `dark`. - /// See https://github.com/dandavison/delta#custom-color-themes. If diff output is supplied on - /// standard input then this will be used for the demo. For example: `git show | delta - /// --show-themes`. By default shows dark or light themes only, according to whether delta is in - /// dark or light mode (as set by the user or inferred from BAT_THEME). To control the themes - /// shown, use --dark or --light, or both, on the command line together with this option. - pub show_themes: bool, + pub commit_style: String, - #[clap(long = "show-colors")] - /// Show available named colors. + #[clap(long = "dark")] + /// Use default colors appropriate for a dark terminal background. /// - /// In addition to named colors, arbitrary colors can be specified using RGB hex codes. See - /// COLORS section. - pub show_colors: bool, + /// For more control, see the style options and --syntax-theme. + pub dark: bool, - #[clap(long = "parse-ansi")] - /// Display ANSI color escape sequences in human-readable form. + #[clap(long = "default-language", value_name = "LANGUAGE")] + /// Default language used for syntax highlighting. /// - /// Example usage: git show --color=always | delta --parse-ansi - /// This can be used to help identify input style strings to use with map-styles. - pub parse_ansi: bool, + /// Used when the language cannot be inferred from a filename. It will typically make sense to + /// set this in per-repository git config (.git/config) + pub default_language: Option<String>, - #[clap(long = "no-gitconfig")] - /// Do not read any settings from git config. + #[clap(long = "diff-highlight")] + /// Emulate diff-highlight. /// - /// See GIT CONFIG section. - pub no_gitconfig: bool, + /// (https://github.com/git/git/tree/master/contrib/diff-highlight) + pub diff_highlight: bool, - #[clap(long = "raw")] - /// Do not alter the input in any way. + #[clap(long = "diff-so-fancy")] + /// Emulate diff-so-fancy. /// - /// This is mainly intended for testing delta. - pub raw: bool, + /// (https://github.com/so-fancy/diff-so-fancy) + pub diff_so_fancy: bool, - #[clap(long = "color-only")] - /// Do not alter the input structurally in any way. + #[clap( + long = "diff-stat-align-width", + default_value = "48", + value_name = "WIDTH" + )] + /// Width allocated for file paths in a diff stat section. /// - /// But color and highlight hunk lines according to your delta configuration. This is mainly - /// intended for other tools that use delta. - pub color_only: bool, + /// If a relativized file path exceeds this width then the diff stat will be misaligned. + pub diff_stat_align_width: usize, - //////////////////////////////////////////////////////////////////////////////////////////// #[clap(long = "features", value_name = "FEATURE_NAMES")] /// Names of delta features to activate (space-separated). /// @@ -349,134 +326,185 @@ pub struct Opt { /// side-by-side temporarily. pub features: Option<String>, - #[clap(long = "syntax-theme", value_name = "THEME_NAME")] - /// The syntax-highlighting theme to use. - /// - /// Use --show-syntax-themes to demo available themes. Defaults to the value of the BAT_THEME - /// environment variable, if that contains a valid theme name. --syntax-theme=none disables all - /// syntax highlighting. - pub syntax_theme: Option<String>, - #[clap( - long = "minus-style", - default_value = "normal auto", - value_name = "STYLE_STRING" + long = "file-added-label", + default_value = "added:", + value_name = "STRING" )] - /// Style string for removed lines. + /// Text to display in front of an added file path. /// - /// See STYLES section. - pub minus_style: String, + /// Used in the default value of navigate-regex. + pub file_added_label: String, #[clap( - long = "zero-style", - default_value = "syntax normal", - value_name = "STYLE_STRING" + long = "file-copied-label", + default_value = "copied:", + value_name = "STRING" )] - /// Style string for unchanged lines. - /// - /// See STYLES section. - pub zero_style: String, + /// Text to display in front of a copied file path. + pub file_copied_label: String, #[clap( - long = "plus-style", - default_value = "syntax auto", + long = "file-decoration-style", + default_value = "blue ul", value_name = "STYLE_STRING" )] - /// Style string for added lines. + /// Style string for the file decoration. /// - /// See STYLES section. - pub plus_style: String, + /// See STYLES section. The style string should contain one of the special attributes 'box', + /// 'ul' (underline), 'ol' (overline), or the combination 'ul ol'. + pub file_decoration_style: String, #[clap( - long = "minus-emph-style", - default_value = "normal auto", - value_name = "STYLE_STRING" + long = "file-modified-label", + default_value = "", + value_name = "STRING" )] - /// Style string for emphasized sections of removed lines. + /// Text to display in front of a modified file path. /// - /// See STYLES section. - pub minus_emph_style: String, + /// Used in the default value of navigate-regex. + pub file_modified_label: String, #[clap( - long = "minus-non-emph-style", - default_value = "minus-style", - value_name = "STYLE_STRING" + long = "file-removed-label", + default_value = "removed:", + value_name = "STRING" )] - /// Style string for non-emphasized sections of removed lines that have an emphasized section. + /// Text to display in front of a removed file path. /// - /// See STYLES section. - pub minus_non_emph_style: String, + /// Used in the default value of navigate-regex. + pub file_removed_label: String, #[clap( - long = "plus-emph-style", - default_value = "syntax auto", - value_name = "STYLE_STRING" + long = "file-renamed-label", + default_value = "renamed:", + value_name = "STRING" )] - /// Style string for emphasized sections of added lines. + /// Text to display in front of a renamed file path. /// - /// See STYLES section. - pub plus_emph_style: String, + /// Used in the default value of navigate-regex. + pub file_renamed_label: String, #[clap( - long = "plus-non-emph-style", - default_value = "plus-style", + long = "file-style", + default_value = "blue", value_name = "STYLE_STRING" )] - /// Style string for non-emphasized sections of added lines that have an emphasized section. + /// Style string for the file section. /// - /// See STYLES section. - pub plus_non_emph_style: String, + /// See STYLES section. The style 'omit' can be used to remove the file section from the output. + pub file_style: String, + + #[structopt(long = "file-transformation", value_name = "SED_COMMAND")] + /// Sed-style command transforming file paths for display. + pub file_regex_replacement: Option<String>, + + #[clap(long = "grep-context-line-style", value_name = "STYLE_STRING")] + /// Style string for non-matching lines of grep output. + /// + /// See STYLES section. Defaults to zero-style. + pub grep_context_line_style: Option<String>, + + #[clap(long = "grep-file-style", value_name = "STYLE_STRING")] + /// Style string for file paths in grep output. + /// + /// See STYLES section. Defaults to hunk-header-file-path-style. + pub grep_file_style: Option<String>, + + #[clap(long = "grep-line-number-style", value_name = "STYLE_STRING")] + /// Style string for line numbers in grep output. + /// + /// See STYLES section. Defaults to hunk-header-line-number-style. + pub grep_line_number_style: Option<String>, + + #[clap(long = "grep-match-line-style", value_name = "STYLE_STRING")] + /// Style string for matching lines of grep output. + /// + /// See STYLES section. Defaults to plus-style. + pub grep_match_line_style: Option<String>, + + #[clap(long = "grep-match-word-style", value_name = "STYLE_STRING")] + /// Style string for the matching substrings within a matching line of grep output. + /// + /// See STYLES section. Defaults to plus-style. + pub grep_match_word_style: Option<String>, #[clap( - long = "commit-style", - default_value = "raw", - value_name = "STYLE_STRING" + long = "grep-separator-symbol", + default_value = ":", + value_name = "SEPARATOR" )] - /// Style string for the commit hash line. + /// Separator symbol printed after the file path and line number in grep output. /// - /// See STYLES section. The style 'omit' can be used to remove the commit hash line from the - /// output. - pub commit_style: String, + /// Defaults to ":" for both match and context lines, since many terminal emulators recognize + /// constructs like "/path/to/file:7:". However, standard grep output uses "-" for context + /// lines: set this option to "keep" to keep the original separator symbols. + pub grep_separator_symbol: String, #[clap( - long = "commit-decoration-style", - default_value = "", + long = "hunk-header-decoration-style", + default_value = "blue box", value_name = "STYLE_STRING" )] - /// Style string for the commit hash decoration. + /// Style string for the hunk-header decoration. /// /// See STYLES section. The style string should contain one of the special attributes 'box', /// 'ul' (underline), 'ol' (overline), or the combination 'ul ol'. - pub commit_decoration_style: String, + pub hunk_header_decoration_style: String, - #[clap(long = "commit-regex", default_value = r"^commit ")] - /// Regular expression used to identify the commit line when parsing git output. - pub commit_regex: String, + #[clap( + long = "hunk-header-file-style", + default_value = "blue", + value_name = "STYLE_STRING" + )] + /// Style string for the file path part of the hunk-header. + /// + /// See STYLES section. The file path will only be displayed if hunk-header-style contains the + /// 'file' special attribute. + pub hunk_header_file_style: String, #[clap( - long = "file-style", + long = "hunk-header-line-number-style", default_value = "blue", value_name = "STYLE_STRING" )] - /// Style string for the file section. + /// Style string for the line number part of the hunk-header. /// - /// See STYLES section. The style 'omit' can be used to remove the file section from the output. - pub file_style: String, + /// See STYLES section. The line number will only be displayed if hunk-header-style contains the + /// 'line-number' special attribute. + pub hunk_header_line_number_style: String, #[clap( - long = "file-decoration-style", - default_value = "blue ul", + long = "hunk-header-style", + default_value = "line-number syntax", value_name = "STYLE_STRING" )] - /// Style string for the file decoration. + /// Style string for the hunk-header. /// - /// See STYLES section. The style string should contain one of the special attributes 'box', - /// 'ul' (underline), 'ol' (overline), or the combination 'ul ol'. - pub file_decoration_style: String, + /// See STYLES section. Special attributes 'file' and 'line-number' can be used to include the + /// file path, and number of first hunk line, in the hunk header. The style 'omit' can be used + /// to remove the hunk header section from the output. + pub hunk_header_style: String, - #[structopt(long = "file-transformation", value_name = "SED_COMMAND")] - /// Sed-style command transforming file paths for display. - pub file_regex_replacement: Option<String>, + #[clap(long = "hunk-label", default_value = "", value_name = "STRING")] + /// Text to display in front of a hunk header. + /// + /// Used in the default value of navigate-regex. + pub hunk_label: String, + + #[clap(long = "hyperlinks")] + /// Render commit hashes, file names, and line numbers as hyperlinks. + /// + /// Following the hyperlink spec for terminal emulators: + /// https://gist.github.com/egmontkob/eb114294efbcd5adb1944c9f3cb5feda. By default, file names + /// and line numbers link to the local file using a file URL, whereas commit hashes link to the + /// commit in GitHub, if the remote repository is hosted by GitHub. See + /// --hyperlinks-file-link-format for full control over the file URLs emitted. Hyperlinks are + /// supported by several common terminal emulators. To make them work, you must use less version + /// >= 581 with the -R flag (or use -r with older less versions, but this will break e.g. + /// --navigate). If you use tmux, then you will also need a patched fork of tmux (see + /// https://github.com/dandavison/tmux). + pub hyperlinks: bool, #[clap(long = "hyperlinks-commit-link-format", value_name = "FORMAT_STRING")] /// Format string for commit hyperlinks (requiraes --hyperlinks). @@ -503,232 +531,156 @@ pub struct Opt { pub hyperlinks_file_link_format: String, #[clap( - long = "hunk-header-style", - default_value = "line-number syntax", + long = "inline-hint-style", + default_value = "blue", value_name = "STYLE_STRING" )] - /// Style string for the hunk-header. + /// Style string for short inline hint text. /// - /// See STYLES section. Special attributes 'file' and 'line-number' can be used to include the - /// file path, and number of first hunk line, in the hunk header. The style 'omit' can be used - /// to remove the hunk header section from the output. - pub hunk_header_style: String, + /// This styles certain content added by delta to the original diff such as special characters + /// to highlight tabs, and the symbols used to indicate wrapped lines. See STYLES section. + pub inline_hint_style: String, #[clap( - long = "hunk-header-file-style", - default_value = "blue", - value_name = "STYLE_STRING" + long = "inspect-raw-lines", + default_value = "true", + value_name = "true|false" )] - /// Style string for the file path part of the hunk-header. + /// Kill-switch for --color-moved support. /// - /// See STYLES section. The file path will only be displayed if hunk-header-style contains the - /// 'file' special attribute. - pub hunk_header_file_style: String, + /// Whether to examine ANSI color escape sequences in raw lines received from Git and handle + /// lines colored in certain ways specially. This is on by default: it is how Delta supports + /// Git's --color-moved feature. Set this to "false" to disable this behavior. + pub inspect_raw_lines: String, - #[clap( - long = "hunk-header-line-number-style", - default_value = "blue", - value_name = "STYLE_STRING" - )] - /// Style string for the line number part of the hunk-header. + #[clap(long = "keep-plus-minus-markers")] + /// Prefix added/removed lines with a +/- character, as git does. /// - /// See STYLES section. The line number will only be displayed if hunk-header-style contains the - /// 'line-number' special attribute. - pub hunk_header_line_number_style: String, + /// By default, delta does not emit any prefix, so code can be copied directly from delta's + /// output. + pub keep_plus_minus_markers: bool, - #[clap( - long = "hunk-header-decoration-style", - default_value = "blue box", - value_name = "STYLE_STRING" - )] - /// Style string for the hunk-header decoration. + #[clap(long = "light")] + /// Use default colors appropriate for a light terminal background. /// - /// See STYLES section. The style string should contain one of the special attributes 'box', - /// 'ul' (underline), 'ol' (overline), or the combination 'ul ol'. - pub hunk_header_decoration_style: String, + /// For more control, see the style options and --syntax-theme. + pub light: bool, #[clap( - long = "merge-conflict-begin-symbol", - default_value = "▼", - value_name = "STRING" + long = "line-buffer-size", + default_value = "32", + value_name = "NUMBER_OF_LINES" )] - /// String marking the beginning of a merge conflict region. + /// Size of internal line buffer. /// - /// The string will be repeated until it reaches the required length. - pub merge_conflict_begin_symbol: String, + /// Delta compares the added and removed versions of nearby lines in order to detect and + /// highlight changes at the level of individual words/tokens. Therefore, nearby lines must be + /// buffered internally before they are painted and emitted. Increasing this value might improve + /// highlighting of some large diff hunks. However, setting this to a high value will adversely + /// affect delta's performance when entire files are added/removed. + pub line_buffer_size: usize, - #[clap( - long = "merge-conflict-end-symbol", - default_value = "▲", - value_name = "STRING" - )] - /// String marking the end of a merge conflict region. + #[clap(long = "line-fill-method", value_name = "STRING")] + /// Line-fill method in side-by-side mode. /// - /// The string will be repeated until it reaches the required length. - pub merge_conflict_end_symbol: String, + /// How to extend the background color to the end of the line in side-by-side mode. Can be ansi + /// (default) or spaces (default if output is not to a terminal). Has no effect if + /// --width=variable is given. + pub line_fill_method: Option<String>, - #[clap( - long = "merge-conflict-ours-diff-header-style", - default_value = "normal", - value_name = "STYLE_STRING" - )] - /// Style string for the header above the 'ours' branch merge conflict diff. + #[clap(short = 'n', long = "line-numbers")] + /// Display line numbers next to the diff. /// - /// See STYLES section. - pub merge_conflict_ours_diff_header_style: String, + /// See LINE NUMBERS section. + pub line_numbers: bool, #[clap( - long = "merge-conflict-ours-diff-header-decoration-style", - default_value = "box", - value_name = "STYLE_STRING" + long = "line-numbers-left-format", + default_value = "{nm:^4}⋮", + value_name = "FORMAT_STRING" )] - /// Style string for the decoration of the header above the 'ours' merge conflict diff. + /// Format string for the left column of line numbers. /// - /// This styles the decoration of the header above the diff between the ancestral commit and the - /// 'ours' branch. See STYLES section. The style string should contain one of the special - /// attributes 'box', 'ul' (underline), 'ol' (overline), or the combination 'ul ol'. - pub merge_conflict_ours_diff_header_decoration_style: String, + /// A typical value would be "{nm:^4}⋮" which means to display the line numbers of the minus + /// file (old version), center-aligned, padded to a width of 4 characters, followed by a + /// dividing character. See the LINE NUMBERS section. + pub line_numbers_left_format: String, #[clap( - long = "merge-conflict-theirs-diff-header-style", - default_value = "normal", + long = "line-numbers-left-style", + default_value = "auto", value_name = "STYLE_STRING" )] - /// Style string for the header above the 'theirs' branch merge conflict diff. + /// Style string for the left column of line numbers. /// - /// This styles the header above the diff between the ancestral commit and 'their' branch. See - /// STYLES section. - pub merge_conflict_theirs_diff_header_style: String, + /// See STYLES and LINE NUMBERS sections. + pub line_numbers_left_style: String, #[clap( - long = "merge-conflict-theirs-diff-header-decoration-style", - default_value = "box" + long = "line-numbers-minus-style", + default_value = "auto", + value_name = "STYLE_STRING" )] - /// Style string for the decoration of the header above the 'theirs' merge conflict diff. - /// - /// This styles the decoration of the header above the diff between the ancestral commit and - /// 'their' branch. See STYLES section. The style string should contain one of the special - /// attributes 'box', 'ul' (underline), 'ol' (overline), or the combination 'ul ol'. - pub merge_conflict_theirs_diff_header_decoration_style: String, - - #[clap(long = "map-styles", value_name = "STYLES_MAP")] - /// Map styles encountered in raw input to desired output styles. + /// Style string for line numbers in the old (minus) version of the file. /// - /// An example is --map-styles='bold purple => red "#eeeeee", bold cyan => syntax "#eeeeee"' - pub map_styles: Option<String>, + /// See STYLES and LINE NUMBERS sections. + pub line_numbers_minus_style: String, #[clap( - long = "blame-format", - default_value = "{timestamp:<15} {author:<15.14} {commit:<8}", - value_name = "FORMAT_STRING" + long = "line-numbers-plus-style", + default_value = "auto", + value_name = "STYLE_STRING" )] - /// Format string for git blame commit metadata. + /// Style string for line numbers in the new (plus) version of the file. /// - /// Available placeholders are "{timestamp}", "{author}", and "{commit}". - pub blame_format: String, + /// See STYLES and LINE NUMBERS sections. + pub line_numbers_plus_style: String, #[clap( - long = "blame-separator", - default_value = "│", - value_name = "SEPARATOR_STRING" + long = "line-numbers-right-format", + default_value = "{np:^4}│", + value_name = "FORMAT_STRING" )] - /// Separator between the commit metadata and code sections of a git blame line. - pub blame_separator: String, - - #[clap(long = "blame-separator-style", value_name = "STYLE_STRING")] - /// Style string for the separator between the commit metadata and code sections of a git blame line. - pub blame_separator_style: Option<String>, - - #[clap(long = "blame-code-style", value_name = "STYLE_STRING")] - /// Style string for the code section of a git blame line. - /// - /// By default the code will be syntax-highlighted with the same background color as the blame - /// format section of the line (the background color is determined by blame-palette). E.g. - /// setting this option to 'syntax' will syntax-highlight the code with no background color. - pub blame_code_style: Option<String>, - - #[clap(long = "blame-palette", value_name = "COLORS")] - /// Background colors used for git blame lines (space-separated string). + /// Format string for the right column of line numbers. /// - /// Lines added by the same commit are painted with the same color; colors are recycled as - /// needed. - pub blame_palette: Option<String>, + /// A typical value would be "{np:^4}│ " which means to display the line numbers of the plus + /// file (new version), center-aligned, padded to a width of 4 characters, followed by a + /// dividing character, and a space. See the LINE NUMBERS section. + pub line_numbers_right_format: String, #[clap( - long = "blame-timestamp-format", - default_value = "%Y-%m-%d %H:%M:%S %z", - value_name = "TIMESTAMP_FORMAT_STRING" + long = "line-numbers-right-style", + default_value = "auto", + value_name = "STYLE_STRING" )] - /// Format of `git blame` timestamp in raw git output received by delta. - pub blame_timestamp_format: String, - - #[clap(long = "grep-match-line-style", value_name = "STYLE_STRING")] - /// Style string for matching lines of grep output. - /// - /// See STYLES section. Defaults to plus-style. - pub grep_match_line_style: Option<String>, - - #[clap(long = "grep-match-word-style", value_name = "STYLE_STRING")] - /// Style string for the matching substrings within a matching line of grep output. - /// - /// See STYLES section. Defaults to plus-style. - pub grep_match_word_style: Option<String>, - - #[clap(long = "grep-context-line-style", value_name = "STYLE_STRING")] - /// Style string for non-matching lines of grep output. - /// - /// See STYLES section. Defaults to zero-style. - pub grep_context_line_style: Option<String>, - - #[clap(long = "grep-file-style", value_name = "STYLE_STRING")] - /// Style string for file paths in grep output. - /// - /// See STYLES section. Defaults to hunk-header-file-path-style. - pub grep_file_style: Option<String>, - - #[clap(long = "grep-line-number-style", value_name = "STYLE_STRING")] - /// Style string for line numbers in grep output. + /// Style string for the right column of line numbers. /// - /// See STYLES section. Defaults to hunk-header-line-number-style. - pub grep_line_number_style: Option<String>, + /// See STYLES and LINE NUMBERS sections. + pub line_numbers_right_style: String, #[clap( - long = "grep-separator-symbol", - default_value = ":", - value_name = "SEPARATOR" + long = "line-numbers-zero-style", + default_value = "auto", + value_name = "STYLE_STRING" )] - /// Separator symbol printed after the file path and line number in grep output. + /// Style string for line numbers in unchanged (zero) lines. /// - /// Defaults to ":" for both match and context lines, since many terminal emulators recognize - /// constructs like "/path/to/file:7:". However, standard grep output uses "-" for context - /// lines: set this option to "keep" to keep the original separator symbols. - pub grep_separator_symbol: String, + /// See STYLES and LINE NUMBERS sections. + pub line_numbers_zero_style: String, - #[clap(long = "default-language", value_name = "LANGUAGE")] - /// Default language used for syntax highlighting. - /// - /// Used when the language cannot be inferred from a filename. It will typically make sense to - /// set this in per-repository git config (.git/config) - pub default_language: Option<String>, + #[clap(long = "list-languages")] + /// List supported languages and associated file extensions. + pub list_languages: bool, - #[clap( - long = "inline-hint-style", - default_value = "blue", - value_name = "STYLE_STRING" - )] - /// Style string for short inline hint text. - /// - /// This styles certain content added by delta to the original diff such as special characters - /// to highlight tabs, and the symbols used to indicate wrapped lines. See STYLES section. - pub inline_hint_style: String, + #[clap(long = "list-syntax-themes")] + /// List available syntax-highlighting color themes. + pub list_syntax_themes: bool, - #[clap(long = "word-diff-regex", default_value = r"\w+", value_name = "REGEX")] - /// Regular expression defining a 'word' in within-line diff algorithm. + #[clap(long = "map-styles", value_name = "STYLES_MAP")] + /// Map styles encountered in raw input to desired output styles. /// - /// The regular expression used to decide what a word is for the within-line highlight - /// algorithm. For less fine-grained matching than the default try --word-diff-regex="\S+" - /// --max-line-distance=1.0 (this is more similar to `git --word-diff`). - pub tokenization_regex: String, + /// An example is --map-styles='bold purple => red "#eeeeee", bold cyan => syntax "#eeeeee"' + pub map_styles: Option<String>, #[clap( long = "max-line-distance", @@ -743,176 +695,214 @@ pub struct Opt { pub max_line_distance: f64, #[clap( - long = "line-numbers-minus-style", - default_value = "auto", - value_name = "STYLE_STRING" + long = "max-line-length", + default_value = "512", + value_name = "NUMBER_OF_CHARACTERS" )] - /// Style string for line numbers in the old (minus) version of the file. + /// Truncate lines longer than this. /// - /// See STYLES and LINE NUMBERS sections. - pub line_numbers_minus_style: String, + /// To prevent any truncation, set to zero. Note that delta will be slow on very long lines + /// (e.g. minified .js) if truncation is disabled. When wrapping lines it is automatically set + /// to fit at least all visible characters. + pub max_line_length: usize, #[clap( - long = "line-numbers-zero-style", - default_value = "auto", - value_name = "STYLE_STRING" + long = "merge-conflict-begin-symbol", + default_value = "▼", + value_name = "STRING" )] - /// Style string for line numbers in unchanged (zero) lines. + /// String marking the beginning of a merge conflict region. /// - /// See STYLES and LINE NUMBERS sections. - pub line_numbers_zero_style: String, + /// The string will be repeated until it reaches the required length. + pub merge_conflict_begin_symbol: String, #[clap( - long = "line-numbers-plus-style", - default_value = "auto", - value_name = "STYLE_STRING" + long = "merge-conflict-end-symbol", + default_value = "▲", + value_name = "STRING" )] - /// Style string for line numbers in the new (plus) version of the file. + /// String marking the end of a merge conflict region. /// - /// See STYLES and LINE NUMBERS sections. - pub line_numbers_plus_style: String, + /// The string will be repeated until it reaches the required length. + pub merge_conflict_end_symbol: String, #[clap( - long = "line-numbers-left-format", - default_value = "{nm:^4}⋮", - value_name = "FORMAT_STRING" + long = "merge-conflict-ours-diff-header-decoration-style", + default_value = "box", + value_name = "STYLE_STRING" )] - /// Format string for the left column of line numbers. + /// Style string for the decoration of the header above the 'ours' merge conflict diff. /// - /// A typical value would be "{nm:^4}⋮" which means to display the line numbers of the minus - /// file (old version), center-aligned, padded to a width of 4 characters, followed by a - /// dividing character. See the LINE NUMBERS section. - pub line_numbers_left_format: String, + /// This styles the decoration of the header above the diff between the ancestral commit and the + /// 'ours' branch. See STYLES section. The style string should contain one of the special + /// attributes 'box', 'ul' (underline), 'ol' (overline), or the combination 'ul ol'. + pub merge_conflict_ours_diff_header_decoration_style: String, #[clap( - long = "line-numbers-right-format", - default_value = "{np:^4}│", - value_name = "FORMAT_STRING" + long = "merge-conflict-ours-diff-header-style", + default_value = "normal", + value_name = "STYLE_STRING" )] - /// Format string for the right column of line numbers. + /// Style string for the header above the 'ours' branch merge conflict diff. /// - /// A typical value would be "{np:^4}│ " which means to display the line numbers of the plus - /// file (new version), center-aligned, padded to a width of 4 characters, followed by a - /// dividing character, and a space. See the LINE NUMBERS section. - pub line_numbers_right_format: String, + /// See STYLES section. + pub merge_conflict_ours_diff_header_style: String, #[clap( - long = "line-numbers-left-style", - default_value = "auto", - value_name = "STYLE_STRING" + long = "merge-conflict-theirs-diff-header-decoration-style", + default_value = "box" )] - /// Style string for the left column of line numbers. + /// Style string for the decoration of the header above the 'theirs' merge conflict diff. /// - /// See STYLES and LINE NUMBERS sections. - pub line_numbers_left_style: String, + /// This styles the decoration of the header above the diff between the ancestral commit and + /// 'their' branch. See STYLES section. The style string should contain one of the special + /// attributes 'box', 'ul' (underline), 'ol' (overline), or the combination 'ul ol'. + pub merge_conflict_theirs_diff_header_decoration_style: String, #[clap( - long = "line-numbers-right-style", - default_value = "auto", + long = "merge-conflict-theirs-diff-header-style", + default_value = "normal", value_name = "STYLE_STRING" )] - /// Style string for the right column of line numbers. + /// Style string for the header above the 'theirs' branch merge conflict diff. /// - /// See STYLES and LINE NUMBERS sections. - pub line_numbers_right_style: String, + /// This styles the header above the diff between the ancestral commit and 'their' branch. See + /// STYLES section. + pub merge_conflict_theirs_diff_header_style: String, #[clap( - long = "wrap-max-lines", - default_value = "2", - value_name = "NUMBER_OF_LINES" + long = "--minus-empty-line-marker-style", + default_value = "normal auto", + value_name = "STYLE_STRING" )] - /// How often a line should be wrapped if it does not fit. - /// - /// Zero means to never wrap. Any content which does not fit will be truncated. A value of - /// "unlimited" means a line will be wrapped as many times as required. - pub wrap_max_lines: String, - - #[clap(long = "wrap-left-symbol", default_value = "↵", value_name = "STRING")] - /// End-of-line wrapped content symbol (left-aligned). + /// Style string for removed empty line marker. /// - /// Symbol added to the end of a line indicating that the content has been wrapped onto the next - /// line and continues left-aligned. - pub wrap_left_symbol: String, + /// Used only if --minus-style has no background color. + pub minus_empty_line_marker_style: String, - #[clap(long = "wrap-right-symbol", default_value = "↴", value_name = "STRING")] - /// End-of-line wrapped content symbol (right-aligned). + #[clap( + long = "minus-emph-style", + default_value = "normal auto", + value_name = "STYLE_STRING" + )] + /// Style string for emphasized sections of removed lines. /// - /// Symbol added to the end of a line indicating that the content has been wrapped onto the next - /// line and continues right-aligned. - pub wrap_right_symbol: String, + /// See STYLES section. + pub minus_emph_style: String, #[clap( - long = "wrap-right-percent", - default_value = "37.0", - value_name = "PERCENT" + long = "minus-non-emph-style", + default_value = "minus-style", + value_name = "STYLE_STRING" )] - /// Threshold for right-aligning wrapped content. + /// Style string for non-emphasized sections of removed lines that have an emphasized section. /// - /// If the length of the remaining wrapped content, as a percentage of width, is less than this - /// quantity it will be right-aligned. Otherwise it will be left-aligned. - pub wrap_right_percent: String, + /// See STYLES section. + pub minus_non_emph_style: String, #[clap( - long = "wrap-right-prefix-symbol", - default_value = "…", - value_name = "STRING" + long = "minus-style", + default_value = "normal auto", + value_name = "STYLE_STRING" )] - /// Pre-wrapped content symbol (right-aligned). + /// Style string for removed lines. /// - /// Symbol displayed in front of right-aligned wrapped content. - pub wrap_right_prefix_symbol: String, + /// See STYLES section. + pub minus_style: String, + + #[clap(long = "navigate")] + /// Activate diff navigation. + /// + /// Use n to jump forwards and N to jump backwards. To change the file labels used see + /// --file-modified-label, --file-removed-label, --file-added-label, --file-renamed-label. + pub navigate: bool, #[clap(long = "navigate-regex", value_name = "REGEX")] /// Regular expression defining navigation stop points. pub navigate_regex: Option<String>, + #[clap(long = "no-gitconfig")] + /// Do not read any settings from git config. + /// + /// See GIT CONFIG section. + pub no_gitconfig: bool, + + #[clap(long = "pager", value_name = "PAGER_COMMAND")] + /// Which pager to use. + /// + /// The default pager is `less`. You can also change pager by setting the environment variables + /// DELTA_PAGER, BAT_PAGER, or PAGER (and that is their order of priority). This option + /// overrides all environment variables above. + pub pager: Option<String>, + #[clap( - long = "file-modified-label", - default_value = "", - value_name = "STRING" + long = "paging", + default_value = "auto", + value_name = "auto|always|never" )] - /// Text to display in front of a modified file path. + /// Whether to use a pager when displaying output. /// - /// Used in the default value of navigate-regex. - pub file_modified_label: String, + /// Options are: auto, always, and never. + pub paging_mode: String, + + #[clap(long = "parse-ansi")] + /// Display ANSI color escape sequences in human-readable form. + /// + /// Example usage: git show --color=always | delta --parse-ansi + /// This can be used to help identify input style strings to use with map-styles. + pub parse_ansi: bool, #[clap( - long = "file-removed-label", - default_value = "removed:", - value_name = "STRING" + long = "plus-emph-style", + default_value = "syntax auto", + value_name = "STYLE_STRING" )] - /// Text to display in front of a removed file path. + /// Style string for emphasized sections of added lines. /// - /// Used in the default value of navigate-regex. - pub file_removed_label: String, + /// See STYLES section. + pub plus_emph_style: String, #[clap( - long = "file-added-label", - default_value = "added:", - value_name = "STRING" + long = "plus-empty-line-marker-style", + default_value = "normal auto", + value_name = "STYLE_STRING" )] - /// Text to display in front of an added file path. + /// Style string for added empty line marker. /// - /// Used in the default value of navigate-regex. - pub file_added_label: String, + /// Used only if --plus-style has no background color. + pub plus_empty_line_marker_style: String, #[clap( - long = "file-copied-label", - default_value = "copied:", - value_name = "STRING" + long = "plus-non-emph-style", + default_value = "plus-style", + value_name = "STYLE_STRING" )] - /// Text to display in front of a copied file path. - pub file_copied_label: String, + /// Style string for non-emphasized sections of added lines that have an emphasized section. + /// + /// See STYLES section. + pub plus_non_emph_style: String, #[clap( - long = "file-renamed-label", - default_value = "renamed:", - value_name = "STRING" + long = "plus-style", + default_value = "syntax auto", + value_name = "STYLE_STRING" )] - /// Text to display in front of a renamed file path. + /// Style string for added lines. /// - /// Used in the default value of navigate-regex. - pub file_renamed_label: String, + /// See STYLES section. + pub plus_style: String, + + #[clap(long = "raw")] + /// Do not alter the input in any way. + /// + /// This is mainly intended for testing delta. + pub raw: bool, + + #[clap(long = "relative-paths")] + /// Output all file paths relative to the current directory. + /// + /// This means that they will resolve correctly when clicked on or used in shell commands. + pub relative_paths: bool, #[clap(long = "right-arrow", default_value = "⟶ ", value_name = "STRING")] /// Text to display with a changed file path. @@ -920,51 +910,50 @@ pub struct Opt { /// For example, a unified diff heading, a rename, or a chmod. pub right_arrow: String, - #[clap(long = "hunk-label", default_value = "", value_name = "STRING")] - /// Text to display in front of a hunk header. + #[clap(long = "show-colors")] + /// Show available named colors. /// - /// Used in the default value of navigate-regex. - pub hunk_label: String, + /// In addition to named colors, arbitrary colors can be specified using RGB hex codes. See + /// COLORS section. + pub show_colors: bool, - #[clap( - long = "max-line-length", - default_value = "512", - value_name = "NUMBER_OF_CHARACTERS" - )] - /// Truncate lines longer than this. + #[clap(long = "show-config")] + /// Display the active values for all Delta options. /// - /// To prevent any truncation, set to zero. Note that delta will be slow on very long lines - /// (e.g. minified .js) if truncation is disabled. When wrapping lines it is automatically set - /// to fit at least all visible characters. - pub max_line_length: usize, + /// Style string options are displayed with foreground and background colors. This can be used to + /// experiment with colors by combining this option with other options such as --minus-style, + /// --zero-style, --plus-style, --light, --dark, etc. + pub show_config: bool, - #[clap(long = "line-fill-method", value_name = "STRING")] - /// Line-fill method in side-by-side mode. + #[clap(long = "show-syntax-themes")] + /// Show example diff for available syntax-highlighting themes. /// - /// How to extend the background color to the end of the line in side-by-side mode. Can be ansi - /// (default) or spaces (default if output is not to a terminal). Has no effect if - /// --width=variable is given. - pub line_fill_method: Option<String>, + /// If diff output is supplied on standard input then this will be used for the demo. For + /// example: `git show | delta --show-syntax-themes`. + pub show_syntax_themes: bool, - #[clap(short = 'w', long = "width", value_name = "WIDTH")] - /// The width of underline/overline decorations. + #[clap(long = "show-themes")] + /// Show example diff for available delta themes. /// - /// Examples: "72" (exactly 72 characters), "-2" (auto-detected terminal width minus 2). An - /// expression such as "74-2" is also valid (equivalent to 72 but may be useful if the caller - /// has a variable holding the value "74"). Use --width=variable to extend decorations and - /// background colors to the end of the text only. Otherwise background colors extend to the - /// full terminal width. - pub width: Option<String>, + /// A delta theme is a delta named feature (see --features) that sets either `light` or `dark`. + /// See https://github.com/dandavison/delta#custom-color-themes. If diff output is supplied on + /// standard input then this will be used for the demo. For example: `git show | delta + /// --show-themes`. By default shows dark or light themes only, according to whether delta is in + /// dark or light mode (as set by the user or inferred from BAT_THEME). To control the themes + /// shown, use --dark or --light, or both, on the command line together with this option. + pub show_themes: bool, - #[clap( - long = "diff-stat-align-width", - default_value = "48", - value_name = "WIDTH" - )] - /// Width allocated for file paths in a diff stat section. + #[clap(short = 's', long = "side-by-side")] + /// Display diffs in side-by-side layout. + pub side_by_side: bool, + + #[clap(long = "syntax-theme", value_name = "THEME_NAME")] + /// The syntax-highlighting theme to use. /// - /// If a relativized file path exceeds this width then the diff stat will be misaligned. - pub diff_stat_align_width: usize, + /// Use --show-syntax-themes to demo available themes. Defaults to the value of the BAT_THEME + /// environment variable, if that contains a valid theme name. --syntax-theme=none disables all + /// syntax highlighting. + pub syntax_theme: Option<String>, #[clap(long = "tabs", default_value = "4", value_name = "NUMBER_OF_SPACES")] /// The number of spaces to replace tab characters with. @@ -989,93 +978,103 @@ pub struct Opt { /// need to do anything. pub true_color: String, - #[clap(long = "24-bit-color", value_name = "auto|always|never")] - /// Deprecated: use --true-color. - pub _24_bit_color: Option<String>, - #[clap( - long = "inspect-raw-lines", - default_value = "true", - value_name = "true|false" + long = "whitespace-error-style", + default_value = "auto auto", + value_name = "STYLE_STRING" )] - /// Kill-switch for --color-moved support. + /// Style string for whitespace errors. /// - /// Whether to examine ANSI color escape sequences in raw lines received from Git and handle - /// lines colored in certain ways specially. This is on by default: it is how Delta supports - /// Git's --color-moved feature. Set this to "false" to disable this behavior. - pub inspect_raw_lines: String, + /// Defaults to color.diff.whitespace if that is set in git config, or else 'magenta reverse'. + pub whitespace_error_style: String, - #[clap(long = "pager", value_name = "PAGER_COMMAND")] - /// Which pager to use. + #[clap(short = 'w', long = "width", value_name = "WIDTH")] + /// The width of underline/overline decorations. /// - /// The default pager is `less`. You can also change pager by setting the environment variables - /// DELTA_PAGER, BAT_PAGER, or PAGER (and that is their order of priority). This option - /// overrides all environment variables above. - pub pager: Option<String>, + /// Examples: "72" (exactly 72 characters), "-2" (auto-detected terminal width minus 2). An + /// expression such as "74-2" is also valid (equivalent to 72 but may be useful if the caller + /// has a variable holding the value "74"). Use --width=variable to extend decorations and + /// background colors to the end of the text only. Otherwise background colors extend to the + /// full terminal width. + pub width: Option<String>, - #[clap( - long = "paging", - default_value = "auto", - value_name = "auto|always|never" - )] - /// Whether to use a pager when displaying output. + #[clap(long = "word-diff-regex", default_value = r"\w+", value_name = "REGEX")] + /// Regular expression defining a 'word' in within-line diff algorithm. /// - /// Options are: auto, always, and never. - pub paging_mode: String, + /// The regular expression used to decide what a word is for the within-line highlight + /// algorithm. For less fine-grained matching than the default try --word-diff-regex="\S+" + /// --max-line-distance=1.0 (this is more similar to `git --word-diff`). + pub tokenization_regex: String, - #[clap(parse(from_os_str))] - /// First file to be compared when delta is being used in diff mode + #[clap(long = "wrap-left-symbol", default_value = "↵", value_name = "STRING")] + /// End-of-line wrapped content symbol (left-aligned). /// - /// `delta file_1 file_2` is equivalent to `diff -u file_1 file_2 | delta`. - pub minus_file: Option<PathBuf>, - - #[clap(parse(from_os_str))] - /// Second file to be compared when delta is being used in diff mode. - pub plus_file: Option<PathBuf>, + /// Symbol added to the end of a line indicating that the content has been wrapped onto the next + /// line and continues left-aligned. + pub wrap_left_symbol: String, #[clap( - long = "--minus-empty-line-marker-style", - default_value = "normal auto", - value_name = "STYLE_STRING" + long = "wrap-max-lines", + default_value = "2", + value_name = "NUMBER_OF_LINES" )] - /// Style string for removed empty line marker. + /// How often a line should be wrapped if it does not fit. /// - /// Used only if --minus-style has no background color. - pub minus_empty_line_marker_style: String, + /// Zero means to never wrap. Any content which does not fit will be truncated. A value of + /// "unlimited" means a line will be wrapped as many times as required. + pub wrap_max_lines: String, #[clap( - long = "--plus-empty-line-marker-style", - default_value = "normal auto", - value_name = "STYLE_STRING" + long = "wrap-right-percent", + default_value = "37.0", + value_name = "PERCENT" )] - /// Style string for added empty line marker. + /// Threshold for right-aligning wrapped content. /// - /// Used only if --plus-style has no background color. - pub plus_empty_line_marker_style: String, + /// If the length of the remaining wrapped content, as a percentage of width, is less than this + /// quantity it will be right-aligned. Otherwise it will be left-aligned. + pub wrap_right_percent: String, #[clap( - long = "whitespace-error-style", - default_value = "auto auto", - value_name = "STYLE_STRING" + long = "wrap-right-prefix-symbol", + default_value = "…", + value_name = "STRING" )] - /// Style string for whitespace errors. + /// Pre-wrapped content symbol (right-aligned). /// - /// Defaults to color.diff.whitespace if that is set in git config, or else 'magenta reverse'. - pub whitespace_error_style: String, + /// Symbol displayed in front of right-aligned wrapped content. + pub wrap_right_prefix_symbol: String, + + #[clap(long = "wrap-right-symbol", default_value = "↴", value_name = "STRING")] + /// End-of-line wrapped content symbol (right-aligned). + /// + /// Symbol added to the end of a line indicating that the content has been wrapped onto the next + /// line and continues right-aligned. + pub wrap_right_symbol: String, #[clap( - long = "line-buffer-size", - default_value = "32", - value_name = "NUMBER_OF_LINES" + long = "zero-style", + default_value = "syntax normal", + value_name = "STYLE_STRING" )] - /// Size of internal line buffer. + /// Style string for unchanged lines. /// - /// Delta compares the added and removed versions of nearby lines in order to detect and - /// highlight changes at the level of individual words/tokens. Therefore, nearby lines must be - /// buffered internally before they are painted and emitted. Increasing this value might improve - /// highlighting of some large diff hunks. However, setting this to a high value will adversely - /// affect delta's performance when entire files are added/removed. - pub line_buffer_size: usize, + /// See STYLES section. + pub zero_style: String, + + #[clap(long = "24-bit-color", value_name = "auto|always|never")] + /// Deprecated: use --true-color. + pub _24_bit_color: Option<String>, + + #[clap(parse(from_os_str))] + /// First file to be compared when delta is being used in diff mode + /// + /// `delta file_1 file_2` is equivalent to `diff -u file_1 file_2 | delta`. + pub minus_file: Option<PathBuf>, + + #[clap(parse(from_os_str))] + /// Second file to be compared when delta is being used in diff mode. + pub plus_file: Option<PathBuf>, #[clap(skip)] pub computed: ComputedValues, |
