LinuxCommandLibrary

delta

View side-by-side diffs with syntax highlighting

TLDR

Compare files or directories

$ delta [path/to/old_file_or_directory] [path/to/new_file_or_directory]
copy

Compare files or directories, showing the line numbers
$ delta [[-n|--line-numbers]] [path/to/old_file_or_directory] [path/to/new_file_or_directory]
copy

Compare files or directories, showing the differences side by side
$ delta [[-s|--side-by-side]] [path/to/old_file_or_directory] [path/to/new_file_or_directory]
copy

Compare files or directories, ignoring any Git configuration settings
$ delta --no-gitconfig [path/to/old_file_or_directory] [path/to/new_file_or_directory]
copy

Compare, rendering commit hashes, file names, and line numbers as hyperlinks, according to the hyperlink spec for terminal emulators
$ delta --hyperlinks [path/to/old_file_or_directory] [path/to/new_file_or_directory]
copy

Display the current settings
$ delta --show-config
copy

Display supported languages and associated file extensions
$ delta --list-languages
copy

SYNOPSIS

delta [OPTIONS] [FILE]
command | delta [OPTIONS]

PARAMETERS

--side-by-side
    Displays diffs with old and new code side-by-side, improving readability for wider terminals.

--line-numbers
    Shows line numbers on both sides of the diff, aiding in code context and referencing.

--syntax-theme
    Specifies the syntax highlighting theme to be used for code within the diff. Many popular themes are supported.

--theme
    Specifies the general color theme for delta's non-syntax-highlighted output elements like headers and line numbers.

--features
    Enables a comma-separated list of named features defined in the configuration, e.g., line-numbers, side-by-side.

--hunk-header-style