lazygit
lazygit settings
| Type | UserConfig |
|---|---|
| File match |
**/lazygit/config.yml
lazygit.yml
.lazygit.yml
|
| Schema URL | https://catalog.lintel.tools/schemas/schemastore/lazygit/latest.json |
| Source | https://raw.githubusercontent.com/jesseduffield/lazygit/master/schema/config.json |
Validate with Lintel
npx @lintel/lintel check
Definitions
Config relating to committing
If true, pass '--signoff' flag when committing
Automatic WYSIWYG wrapping of the commit message as you type
If autoWrapCommitMessage is true, the width to wrap to
Config relating to the commit length indicator
If true, show an indicator of commit message length
pattern to match on. E.g. for 'feature/AB-123' to match on the AB-123 use "^\w+\/(\w+-\w+).*"
Replace directive. E.g. for 'feature/AB-123' to start the commit message with 'AB-123 ' use "[$1] "
The key to trigger the command. Use a single letter or one of the values from https://github.com/jesseduffield/lazygit/blob/master/docs/keybindings/Custom_Keybindings.md
Instead of defining a single custom command, create a menu of custom commands. Useful for grouping related commands together under a single keybinding, and for keeping them out of the global keybindings menu. When using this, all other fields except Key and Description are ignored and must be empty.
The context in which to listen for the key. Valid values are: status, files, worktrees, localBranches, remotes, remoteBranches, tags, commits, reflogCommits, subCommits, commitFiles, stash, and global. Multiple contexts separated by comma are allowed; most useful for "commits, subCommits" or "files, commitFiles".
The command to run (using Go template syntax for placeholder values)
A list of prompts that will request user input before running the final command
Text to display while waiting for command to finish
Label for the custom command when displayed in the keybindings menu
Where the output of the command should go. 'none' discards it, 'terminal' suspends lazygit and runs the command in the terminal (useful for commands that require user input), 'log' streams it to the command log, 'logWithPty' is like 'log' but runs the command in a pseudo terminal (can be useful for commands that produce colored output when the output is a terminal), and 'popup' shows it in a popup.
The title to display in the popup panel if output is set to 'popup'. If left unset, the command will be used as the title.
1 nested properties
The first part of the label
The second part of the label
The value that will be used in the command
Keybinding to invoke this menu option without needing to navigate to it
One of: 'input' | 'menu' | 'confirm' | 'menuFromCommand'
Used to reference the entered value from within the custom command. E.g. a prompt with key: 'Branch' can be referred to as {{.Form.Branch}} in the command
The title to display in the popup panel
The initial value to appear in the text box. Only for input prompts.
2 nested properties
Uses built-in logic to obtain the suggestions. One of 'authors' | 'branches' | 'files' | 'refs' | 'remotes' | 'remoteBranches' | 'tags'
Command to run such that each line in the output becomes a suggestion. Mutually exclusive with 'preset' field.
The message of the confirmation prompt. Only for confirm prompts.
Menu options. Only for menu prompts.
The command to run to generate menu options Only for menuFromCommand prompts.
The regexp to run specifying groups which are going to be kept from the command's output. Only for menuFromCommand prompts.
How to format matched groups from the filter to construct a menu item's value. Only for menuFromCommand prompts.
Like valueFormat but for the labels. If labelFormat is not specified, valueFormat is shown instead.
Only for menuFromCommand prompts.
A Go template expression evaluated against the current form state. If it resolves to empty string or 'false', the prompt is skipped.
Uses built-in logic to obtain the suggestions. One of 'authors' | 'branches' | 'files' | 'refs' | 'remotes' | 'remoteBranches' | 'tags'
Command to run such that each line in the output becomes a suggestion. Mutually exclusive with 'preset' field.
Custom icons for filenames and file extensions See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#custom-files-icon--color
Config relating to git
Array of pagers. Each entry has the following format:
Value of the --color arg in the git diff command. Some pagers want
this to be set to 'always' and some want it set to 'never'
colorArg: "always"
e.g.
diff-so-fancy
delta --dark --paging=never
ydiff -p cat -s --wrap --width={{columnWidth}}
pager: ""
e.g. 'difft --color=always'
externalDiffCommand: ""
If true, Lazygit will use git's diff.external config for paging.
The advantage over externalDiffCommand is that this can be
configured per file type in .gitattributes; see
https://git-scm.com/docs/gitattributes#_defining_an_external_diff_driver.
useExternalDiffGitConfig: false
See https://github.com/jesseduffield/lazygit/blob/master/docs/Custom_Pagers.md for more information.
Config relating to committing
3 nested properties
If true, pass '--signoff' flag when committing
Automatic WYSIWYG wrapping of the commit message as you type
If autoWrapCommitMessage is true, the width to wrap to
Config relating to merging
3 nested properties
If true, run merges in a subprocess so that if a commit message is required, Lazygit will not hang Only applicable to unix users.
Extra args passed to git merge, e.g. --no-ff
The commit message to use for a squash merge commit. Can contain "{{selectedRef}}" and "{{currentBranch}}" placeholders.
list of branches that are considered 'main' branches, used when displaying commits
[
"master",
"main"
]
Prefix to use when skipping hooks. E.g. if set to 'WIP', then pre-commit hooks will be skipped when the commit message starts with 'WIP'
If true, periodically fetch from remote
If true, periodically refresh files and submodules
If not "none", lazygit will automatically fast-forward local branches to match their upstream after fetching. Applies to branches that are not the currently checked out branch, and only to those that are strictly behind their upstream (as opposed to diverged). Possible values: 'none' | 'onlyMainBranches' | 'allBranches'
If true, pass the --all arg to git fetch
If true, lazygit will automatically stage files that used to have merge conflicts but no longer do; and it will also ask you if you want to continue a merge or rebase if you've resolved all conflicts. If false, it won't do either of these things.
Command used when displaying the current branch git log in the main window
Commands used to display git log of all branches in the main window, they will be cycled in order of appearance (array of strings)
[
"git log --graph --all --color=always --abbrev-commit --decorate --date=relative --pretty=medium"
]
If true, git diffs are rendered with the --ignore-all-space flag, which ignores whitespace changes. Can be toggled from within Lazygit with <c-w>.
The number of lines of context to show around each diff hunk. Can be changed from within Lazygit with the { and } keys.
The threshold for considering a file to be renamed, in percent. Can be changed from within Lazygit with the ( and ) keys.
If true, do not spawn a separate process when using GPG
If true, do not allow force pushes
If true, parse emoji strings in commit messages e.g. render :rocket: as 🚀 (This should really be under 'gui', not 'git')
Config for showing the log in the commits view
3 nested properties
One of: 'date-order' | 'author-date-order' | 'topo-order' | 'default' 'topo-order' makes it easier to read the git log graph, but commits may not appear chronologically. See https://git-scm.com/docs/
Can be changed from within Lazygit with Log menu -> Commit sort order (<c-l> in the commits window by default).
This determines whether the git graph is rendered in the commits panel One of 'always' | 'never' | 'when-maximised'
Can be toggled from within lazygit with Log menu -> Show git graph (<c-l> in the commits window by default).
displays the whole git graph by default in the commits view (equivalent to passing the --all argument to git log)
How branches are sorted in the local branches view.
One of: 'date' (default) | 'recency' | 'alphabetical'
Can be changed from within Lazygit with the Sort Order menu (s) in the branches panel.
How branches are sorted in the remote branches view.
One of: 'date' (default) | 'alphabetical'
Can be changed from within Lazygit with the Sort Order menu (s) in the remote branches panel.
When copying commit hashes to the clipboard, truncate them to this length. Set to 40 to disable truncation.
Config relating to the Lazygit UI
See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#custom-branch-color Deprecated: use branchColorPatterns instead
Custom icons for filenames and file extensions See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#custom-files-icon--color
The number of lines you scroll by when scrolling the main window
If true, allow scrolling past the bottom of the content in the main window
One of: 'margin' (default) | 'jump'
The number of spaces per tab; used for everything that's shown in the main view, but probably mostly relevant for diffs. Note that when using a pager, the pager has its own tab width setting, so you need to pass it separately in the pager command.
If true, capture mouse events. When mouse events are captured, it's a little harder to select text: e.g. requiring you to hold the option key when on macOS.
If true, do not show a warning when amending a commit.
If true, do not show a warning when discarding changes in the staging view.
If true, do not show warning when applying/popping the stash
If true, do not show a warning when attempting to commit without any staged files; instead stage all unstaged files.
If true, do not show a warning when rewording a commit via an external editor
If true, switch to a different worktree without confirmation when checking out a branch that is checked out in that worktree
Fraction of the total screen width to use for the left side section. You may want to pick a small number (e.g. 0.2) if you're using a narrow screen, so that you can see more of the main section. Number from 0 to 1.0.
If true, increase the height of the focused side window; creating an accordion effect.
The weight of the expanded side panel, relative to the other panels. 2 means twice as tall as the other panels. Only relevant if expandFocusedSidePanel is true.
Sometimes the main window is split in two (e.g. when the selected file has both staged and unstaged changes). This setting controls how the two sections are split. Options are:
- 'horizontal': split the window horizontally
- 'vertical': split the window vertically
- 'flexible': (default) split the window horizontally if the window is wide enough, otherwise split vertically
How the window is split when in half screen mode (i.e. after hitting '+' once). Possible values:
- 'left': split the window horizontally (side panel on the left, main view on the right)
- 'top': split the window vertically (side panel on top, main view below)
If true, wrap lines in the staging view to the width of the view. This makes it much easier to work with diffs that have long lines, e.g. paragraphs of markdown text.
If true, hunk selection mode will be enabled by default when entering the staging view.
One of 'auto' (default) | 'en' | 'zh-CN' | 'zh-TW' | 'pl' | 'nl' | 'ja' | 'ko' | 'ru' | 'pt'
Format used when displaying time e.g. commit time. Uses Go's time format syntax: https://pkg.go.dev/time#Time.Format
Format used when displaying time if the time is less than 24 hours ago. Uses Go's time format syntax: https://pkg.go.dev/time#Time.Format
Config relating to colors and styles. See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#color-attributes
12 nested properties
Border color of focused window
[
"green",
"bold"
]
Border color of non-focused windows
[
"default"
]
Border color of focused window when searching in that window
[
"cyan",
"bold"
]
Color of keybindings help text in the bottom line
[
"blue"
]
Background color of selected line. See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#highlighting-the-selected-line
[
"blue"
]
Background color of selected line when view doesn't have focus.
[
"bold"
]
Foreground color of copied commit
[
"blue"
]
Background color of copied commit
[
"cyan"
]
Foreground color of marked base commit (for rebase)
[
"blue"
]
Background color of marked base commit (for rebase)
[
"yellow"
]
Color for file with unstaged changes
[
"red"
]
Default text color
[
"default"
]
Config relating to the commit length indicator
1 nested properties
If true, show an indicator of commit message length
If true, show the '5 of 20' footer at the bottom of list views
If true, display the files in the file views as a tree. If false, display the files as a flat list. This can be toggled from within Lazygit with the '`' key, but that will not change the default.
If true, add a "/" root item in the file tree representing the root of the repository. It is only added when necessary, i.e. when there is more than one item at top level.
How to sort files and directories in the file tree. One of: 'mixed' (default) | 'filesFirst' | 'foldersFirst'
If true (default), sort the file tree case-sensitively.
If true, show the number of lines changed per file in the Files view
If true, show a random tip in the command log when Lazygit starts
If true, show the command log
If true, show the bottom line that contains keybinding info and useful buttons. If false, this line will be hidden except to display a loader for an in-progress action.
If true, show jump-to-window keybindings in window titles.
Deprecated: use nerdFontsVersion instead
Nerd fonts version to use. One of: '2' | '3' | empty string (default) If empty, do not show icons.
If true (default), file icons are shown in the file views. Only relevant if NerdFontsVersion is not empty.
Length of author name in (non-expanded) commits view. 2 means show initials only.
Length of author name in expanded commits view. 2 means show initials only.
Length of commit hash in commits view. 0 shows '*' if NF icons aren't on.
If true, show commit hashes alongside branch names in the branches view.
Whether to show the divergence from the base branch in the branches view. One of: 'none' | 'onlyArrow' | 'arrowAndNumber'
Height of the command log view
Whether to split the main window when viewing file changes. One of: 'auto' | 'always' If 'auto', only split the main window when a file has both staged and unstaged changes
Default size for focused window. Can be changed from within Lazygit with '+' and '_' (but this won't change the default). One of: 'normal' (default) | 'half' | 'full'
Window border style. One of 'rounded' (default) | 'single' | 'double' | 'hidden' | 'bold'
If true, show a seriously epic explosion animation when nuking the working tree.
Whether to stack UI components on top of each other. One of 'auto' (default) | 'always' | 'never'
In 'auto' mode, portrait mode will be used if the window width is less than or equal to portraitModeAutoMaxWidth and the window height is greater than or equal to portraitModeAutoMinHeight. Unused when portraitMode is not 'auto'.
In 'auto' mode, portrait mode will be used if the window width is less than or equal to portraitModeAutoMaxWidth and the window height is greater than or equal to portraitModeAutoMinHeight. Unused when portraitMode is not 'auto'.
How things are filtered when typing '/'. One of 'substring' (default) | 'fuzzy'
Config relating to the spinner.
2 nested properties
The frames of the spinner animation.
[
"|",
"/",
"-",
"\\"
]
The "speed" of the spinner in milliseconds.
Status panel view. One of 'dashboard' (default) | 'allBranchesLog'
If true, jump to the Files panel after popping a stash
If true, jump to the Files panel after applying a stash
If true, when using the panel jump keys (default 1 through 5) and target panel is already active, go to next tab instead
Keybindings
77 nested properties
[
"1",
"2",
"3",
"4",
"5"
]
'Files' appended for legacy reasons
'Files' appended for legacy reasons
4 nested properties
19 nested properties
19 nested properties
1 nested properties
27 nested properties
3 nested properties
2 nested properties
1 nested properties
3 nested properties
3 nested properties
1 nested properties
[
"1",
"2",
"3",
"4",
"5"
]
'Files' appended for legacy reasons
'Files' appended for legacy reasons
Config for showing the log in the commits view
One of: 'date-order' | 'author-date-order' | 'topo-order' | 'default' 'topo-order' makes it easier to read the git log graph, but commits may not appear chronologically. See https://git-scm.com/docs/
Can be changed from within Lazygit with Log menu -> Commit sort order (<c-l> in the commits window by default).
This determines whether the git graph is rendered in the commits panel One of 'always' | 'never' | 'when-maximised'
Can be toggled from within lazygit with Log menu -> Show git graph (<c-l> in the commits window by default).
displays the whole git graph by default in the commits view (equivalent to passing the --all argument to git log)
Config relating to merging
If true, run merges in a subprocess so that if a commit message is required, Lazygit will not hang Only applicable to unix users.
Extra args passed to git merge, e.g. --no-ff
The commit message to use for a squash merge commit. Can contain "{{selectedRef}}" and "{{currentBranch}}" placeholders.
Config relating to things outside of Lazygit like how files are opened, copying to clipboard, etc
Command for editing a file. Should contain "{{filename}}".
Command for editing a file at a given line number. Should contain "{{filename}}", and may optionally contain "{{line}}".
Same as EditAtLine, except that the command needs to wait until the window is closed.
Whether lazygit suspends until an edit process returns
For opening a directory in an editor
A built-in preset that sets all of the above settings. Supported presets are defined in the getPreset function in editor_presets.go.
Command for opening a file, as if the file is double-clicked. Should contain "{{filename}}", but doesn't support "{{line}}".
Command for opening a link. Should contain "{{link}}".
CopyToClipboardCmd is the command for copying to clipboard. See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#custom-command-for-copying-to-and-pasting-from-clipboard
ReadFromClipboardCmd is the command for reading the clipboard. See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#custom-command-for-copying-to-and-pasting-from-clipboard
A shell startup file containing shell aliases or shell functions. This will be sourced before running any shell commands, so that shell functions are available in the : command prompt or even in custom commands.
See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#using-aliases-or-functions-in-shell-commands
Value of the --color arg in the git diff command. Some pagers want this to be set to 'always' and some want it set to 'never'
e.g. diff-so-fancy delta --dark --paging=never ydiff -p cat -s --wrap --width={{columnWidth}}
e.g. 'difft --color=always'
If true, Lazygit will use git's diff.external config for paging. The advantage over externalDiffCommand is that this can be configured per file type in .gitattributes; see https://git-scm.com/docs/gitattributes#_defining_an_external_diff_driver.
Background refreshes
File/submodule refresh interval in seconds. Auto-refresh can be disabled via option 'git.autoRefresh'.
Re-fetch interval in seconds. Auto-fetch can be disabled via option 'git.autoFetch'.
Config relating to the spinner.
The frames of the spinner animation.
[
"|",
"/",
"-",
"\\"
]
The "speed" of the spinner in milliseconds.
Config relating to colors and styles. See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#color-attributes
Border color of focused window
[
"green",
"bold"
]
Border color of non-focused windows
[
"default"
]
Border color of focused window when searching in that window
[
"cyan",
"bold"
]
Color of keybindings help text in the bottom line
[
"blue"
]
Background color of selected line. See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#highlighting-the-selected-line
[
"blue"
]
Background color of selected line when view doesn't have focus.
[
"bold"
]
Foreground color of copied commit
[
"blue"
]
Background color of copied commit
[
"cyan"
]
Foreground color of marked base commit (for rebase)
[
"blue"
]
Background color of marked base commit (for rebase)
[
"yellow"
]
Color for file with unstaged changes
[
"red"
]
Default text color
[
"default"
]
Periodic update checks
One of: 'prompt' (default) | 'background' | 'never'
Period in days between update checks
Config relating to the Lazygit UI
60 nested properties
See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#custom-branch-color Deprecated: use branchColorPatterns instead
Custom icons for filenames and file extensions See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#custom-files-icon--color
The number of lines you scroll by when scrolling the main window
If true, allow scrolling past the bottom of the content in the main window
One of: 'margin' (default) | 'jump'
The number of spaces per tab; used for everything that's shown in the main view, but probably mostly relevant for diffs. Note that when using a pager, the pager has its own tab width setting, so you need to pass it separately in the pager command.
If true, capture mouse events. When mouse events are captured, it's a little harder to select text: e.g. requiring you to hold the option key when on macOS.
If true, do not show a warning when amending a commit.
If true, do not show a warning when discarding changes in the staging view.
If true, do not show warning when applying/popping the stash
If true, do not show a warning when attempting to commit without any staged files; instead stage all unstaged files.
If true, do not show a warning when rewording a commit via an external editor
If true, switch to a different worktree without confirmation when checking out a branch that is checked out in that worktree
Fraction of the total screen width to use for the left side section. You may want to pick a small number (e.g. 0.2) if you're using a narrow screen, so that you can see more of the main section. Number from 0 to 1.0.
If true, increase the height of the focused side window; creating an accordion effect.
The weight of the expanded side panel, relative to the other panels. 2 means twice as tall as the other panels. Only relevant if expandFocusedSidePanel is true.
Sometimes the main window is split in two (e.g. when the selected file has both staged and unstaged changes). This setting controls how the two sections are split. Options are:
- 'horizontal': split the window horizontally
- 'vertical': split the window vertically
- 'flexible': (default) split the window horizontally if the window is wide enough, otherwise split vertically
How the window is split when in half screen mode (i.e. after hitting '+' once). Possible values:
- 'left': split the window horizontally (side panel on the left, main view on the right)
- 'top': split the window vertically (side panel on top, main view below)
If true, wrap lines in the staging view to the width of the view. This makes it much easier to work with diffs that have long lines, e.g. paragraphs of markdown text.
If true, hunk selection mode will be enabled by default when entering the staging view.
One of 'auto' (default) | 'en' | 'zh-CN' | 'zh-TW' | 'pl' | 'nl' | 'ja' | 'ko' | 'ru' | 'pt'
Format used when displaying time e.g. commit time. Uses Go's time format syntax: https://pkg.go.dev/time#Time.Format
Format used when displaying time if the time is less than 24 hours ago. Uses Go's time format syntax: https://pkg.go.dev/time#Time.Format
Config relating to colors and styles. See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#color-attributes
12 nested properties
Border color of focused window
[
"green",
"bold"
]
Border color of non-focused windows
[
"default"
]
Border color of focused window when searching in that window
[
"cyan",
"bold"
]
Color of keybindings help text in the bottom line
[
"blue"
]
Background color of selected line. See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#highlighting-the-selected-line
[
"blue"
]
Background color of selected line when view doesn't have focus.
[
"bold"
]
Foreground color of copied commit
[
"blue"
]
Background color of copied commit
[
"cyan"
]
Foreground color of marked base commit (for rebase)
[
"blue"
]
Background color of marked base commit (for rebase)
[
"yellow"
]
Color for file with unstaged changes
[
"red"
]
Default text color
[
"default"
]
Config relating to the commit length indicator
1 nested properties
If true, show an indicator of commit message length
If true, show the '5 of 20' footer at the bottom of list views
If true, display the files in the file views as a tree. If false, display the files as a flat list. This can be toggled from within Lazygit with the '`' key, but that will not change the default.
If true, add a "/" root item in the file tree representing the root of the repository. It is only added when necessary, i.e. when there is more than one item at top level.
How to sort files and directories in the file tree. One of: 'mixed' (default) | 'filesFirst' | 'foldersFirst'
If true (default), sort the file tree case-sensitively.
If true, show the number of lines changed per file in the Files view
If true, show a random tip in the command log when Lazygit starts
If true, show the command log
If true, show the bottom line that contains keybinding info and useful buttons. If false, this line will be hidden except to display a loader for an in-progress action.
If true, show jump-to-window keybindings in window titles.
Deprecated: use nerdFontsVersion instead
Nerd fonts version to use. One of: '2' | '3' | empty string (default) If empty, do not show icons.
If true (default), file icons are shown in the file views. Only relevant if NerdFontsVersion is not empty.
Length of author name in (non-expanded) commits view. 2 means show initials only.
Length of author name in expanded commits view. 2 means show initials only.
Length of commit hash in commits view. 0 shows '*' if NF icons aren't on.
If true, show commit hashes alongside branch names in the branches view.
Whether to show the divergence from the base branch in the branches view. One of: 'none' | 'onlyArrow' | 'arrowAndNumber'
Height of the command log view
Whether to split the main window when viewing file changes. One of: 'auto' | 'always' If 'auto', only split the main window when a file has both staged and unstaged changes
Default size for focused window. Can be changed from within Lazygit with '+' and '_' (but this won't change the default). One of: 'normal' (default) | 'half' | 'full'
Window border style. One of 'rounded' (default) | 'single' | 'double' | 'hidden' | 'bold'
If true, show a seriously epic explosion animation when nuking the working tree.
Whether to stack UI components on top of each other. One of 'auto' (default) | 'always' | 'never'
In 'auto' mode, portrait mode will be used if the window width is less than or equal to portraitModeAutoMaxWidth and the window height is greater than or equal to portraitModeAutoMinHeight. Unused when portraitMode is not 'auto'.
In 'auto' mode, portrait mode will be used if the window width is less than or equal to portraitModeAutoMaxWidth and the window height is greater than or equal to portraitModeAutoMinHeight. Unused when portraitMode is not 'auto'.
How things are filtered when typing '/'. One of 'substring' (default) | 'fuzzy'
Config relating to the spinner.
2 nested properties
The frames of the spinner animation.
[
"|",
"/",
"-",
"\\"
]
The "speed" of the spinner in milliseconds.
Status panel view. One of 'dashboard' (default) | 'allBranchesLog'
If true, jump to the Files panel after popping a stash
If true, jump to the Files panel after applying a stash
If true, when using the panel jump keys (default 1 through 5) and target panel is already active, go to next tab instead
Config relating to git
25 nested properties
Array of pagers. Each entry has the following format:
Value of the --color arg in the git diff command. Some pagers want
this to be set to 'always' and some want it set to 'never'
colorArg: "always"
e.g.
diff-so-fancy
delta --dark --paging=never
ydiff -p cat -s --wrap --width={{columnWidth}}
pager: ""
e.g. 'difft --color=always'
externalDiffCommand: ""
If true, Lazygit will use git's diff.external config for paging.
The advantage over externalDiffCommand is that this can be
configured per file type in .gitattributes; see
https://git-scm.com/docs/gitattributes#_defining_an_external_diff_driver.
useExternalDiffGitConfig: false
See https://github.com/jesseduffield/lazygit/blob/master/docs/Custom_Pagers.md for more information.
Config relating to committing
3 nested properties
If true, pass '--signoff' flag when committing
Automatic WYSIWYG wrapping of the commit message as you type
If autoWrapCommitMessage is true, the width to wrap to
Config relating to merging
3 nested properties
If true, run merges in a subprocess so that if a commit message is required, Lazygit will not hang Only applicable to unix users.
Extra args passed to git merge, e.g. --no-ff
The commit message to use for a squash merge commit. Can contain "{{selectedRef}}" and "{{currentBranch}}" placeholders.
list of branches that are considered 'main' branches, used when displaying commits
[
"master",
"main"
]
Prefix to use when skipping hooks. E.g. if set to 'WIP', then pre-commit hooks will be skipped when the commit message starts with 'WIP'
If true, periodically fetch from remote
If true, periodically refresh files and submodules
If not "none", lazygit will automatically fast-forward local branches to match their upstream after fetching. Applies to branches that are not the currently checked out branch, and only to those that are strictly behind their upstream (as opposed to diverged). Possible values: 'none' | 'onlyMainBranches' | 'allBranches'
If true, pass the --all arg to git fetch
If true, lazygit will automatically stage files that used to have merge conflicts but no longer do; and it will also ask you if you want to continue a merge or rebase if you've resolved all conflicts. If false, it won't do either of these things.
Command used when displaying the current branch git log in the main window
Commands used to display git log of all branches in the main window, they will be cycled in order of appearance (array of strings)
[
"git log --graph --all --color=always --abbrev-commit --decorate --date=relative --pretty=medium"
]
If true, git diffs are rendered with the --ignore-all-space flag, which ignores whitespace changes. Can be toggled from within Lazygit with <c-w>.
The number of lines of context to show around each diff hunk. Can be changed from within Lazygit with the { and } keys.
The threshold for considering a file to be renamed, in percent. Can be changed from within Lazygit with the ( and ) keys.
If true, do not spawn a separate process when using GPG
If true, do not allow force pushes
If true, parse emoji strings in commit messages e.g. render :rocket: as 🚀 (This should really be under 'gui', not 'git')
Config for showing the log in the commits view
3 nested properties
One of: 'date-order' | 'author-date-order' | 'topo-order' | 'default' 'topo-order' makes it easier to read the git log graph, but commits may not appear chronologically. See https://git-scm.com/docs/
Can be changed from within Lazygit with Log menu -> Commit sort order (<c-l> in the commits window by default).
This determines whether the git graph is rendered in the commits panel One of 'always' | 'never' | 'when-maximised'
Can be toggled from within lazygit with Log menu -> Show git graph (<c-l> in the commits window by default).
displays the whole git graph by default in the commits view (equivalent to passing the --all argument to git log)
How branches are sorted in the local branches view.
One of: 'date' (default) | 'recency' | 'alphabetical'
Can be changed from within Lazygit with the Sort Order menu (s) in the branches panel.
How branches are sorted in the remote branches view.
One of: 'date' (default) | 'alphabetical'
Can be changed from within Lazygit with the Sort Order menu (s) in the remote branches panel.
When copying commit hashes to the clipboard, truncate them to this length. Set to 40 to disable truncation.
Periodic update checks
2 nested properties
One of: 'prompt' (default) | 'background' | 'never'
Period in days between update checks
Background refreshes
2 nested properties
File/submodule refresh interval in seconds. Auto-refresh can be disabled via option 'git.autoRefresh'.
Re-fetch interval in seconds. Auto-fetch can be disabled via option 'git.autoFetch'.
If true, show a confirmation popup before quitting Lazygit
If true, exit Lazygit when the user presses escape in a context where there is nothing to cancel/close
Config relating to things outside of Lazygit like how files are opened, copying to clipboard, etc
11 nested properties
Command for editing a file. Should contain "{{filename}}".
Command for editing a file at a given line number. Should contain "{{filename}}", and may optionally contain "{{line}}".
Same as EditAtLine, except that the command needs to wait until the window is closed.
Whether lazygit suspends until an edit process returns
For opening a directory in an editor
A built-in preset that sets all of the above settings. Supported presets are defined in the getPreset function in editor_presets.go.
Command for opening a file, as if the file is double-clicked. Should contain "{{filename}}", but doesn't support "{{line}}".
Command for opening a link. Should contain "{{link}}".
CopyToClipboardCmd is the command for copying to clipboard. See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#custom-command-for-copying-to-and-pasting-from-clipboard
ReadFromClipboardCmd is the command for reading the clipboard. See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#custom-command-for-copying-to-and-pasting-from-clipboard
A shell startup file containing shell aliases or shell functions. This will be sourced before running any shell commands, so that shell functions are available in the : command prompt or even in custom commands.
See https://github.com/jesseduffield/lazygit/blob/master/docs/Config.md#using-aliases-or-functions-in-shell-commands
If true, don't display introductory popups upon opening Lazygit.
User-configured commands that can be invoked from within Lazygit See https://github.com/jesseduffield/lazygit/blob/master/docs/Custom_Command_Keybindings.md
What to do when opening Lazygit outside of a git repo.
- 'prompt': (default) ask whether to initialize a new repo or open in the most recent repo
- 'create': initialize a new repo
- 'skip': open most recent repo
- 'quit': exit Lazygit
If true, display a confirmation when subprocess terminates. This allows you to view the output of the subprocess before returning to Lazygit.
Keybindings
12 nested properties
77 nested properties
[
"1",
"2",
"3",
"4",
"5"
]
'Files' appended for legacy reasons
'Files' appended for legacy reasons