Skip to content

Instantly share code, notes, and snippets.

@atheiman
Last active September 16, 2025 16:07
Show Gist options
  • Select an option

  • Save atheiman/f5aa05aec2dd4bea9d8382c7f9d5bb44 to your computer and use it in GitHub Desktop.

Select an option

Save atheiman/f5aa05aec2dd4bea9d8382c7f9d5bb44 to your computer and use it in GitHub Desktop.
gitconfig showing some common options I use
[user]
name = John Doe
email = [email protected]
username = jdoe01
[alias]
co = checkout
br = branch
st = status
# show cloned repo local path
root = !pwd
[http "https://git.example.com]
# Example configuring git to connect to internal git server with internally signed certificate.
# Get cert body with `openssl s_client -connect git.example.com:443 -showcerts < /dev/null`
sslCAInfo = C:/Users/jdoe01/example-com-internal-ca-cert.pem
# Include other gitconfig based on cloned repo local path
[includeIf "gitdir:~/code/gist.github.com/"]
path = ~/.gitconfig-github
[includeIf "gitdir:~/code/github.com/"]
path = ~/.gitconfig-github
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment