LinuxCommandLibrary

git-var

Display Git logical variables

TLDR

Show Git variables

$ git var -l
copy
Show editor
$ git var GIT_EDITOR
copy
Show author identity
$ git var GIT_AUTHOR_IDENT
copy
Show committer identity
$ git var GIT_COMMITTER_IDENT
copy

SYNOPSIS

git var [variable]

DESCRIPTION

git var shows Git logical variables such as the configured editor, author identity, and committer identity. These values are determined from environment variables and Git configuration.
The command is useful in scripts that need to query Git's resolved settings without parsing config files directly.

PARAMETERS

-l

List all variables.

SEE ALSO

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community