Skip to content

Latest commit

 

History

History
134 lines (120 loc) · 2.58 KB

git.org

File metadata and controls

134 lines (120 loc) · 2.58 KB

Git

The fast distributed version control system

Basic

User

[user]

Set my name:

name = <<name>>

Set my email:

email = <<email>>

Core

[core]

Use global .gitignore:

excludesfile = ~/.gitignore

Alias

[alias]

Alias for graphical log:

grog = log --graph --abbrev-commit --decorate --all \
    --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(dim white \
        ) - %an%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow \
        )%d%C(reset)%n %C(white)%s%C(reset)'

Alias for difftool:

df = difftool

Diff

Change diff tool to ydiff:

[pager]
diff = delta
log = delta
reflog = delta
show = delta

[delta]
features = side-by-side line-numbers decorations
pager = less --mouse --wheel-lines=3
navigate = true
syntax-theme = base16

Global .gitignore

Diff

Patch files:

*.patch

Diff files:

*.diff

Jetbrains

Project settings:

.idea/

Module files:

*.iml

Linux

Temporary files of some editors:

*~

Temporary files which can be created if a process still has a handle open of a deleted file:

.fuse_hidden*

Linux trash folder which might appear on any partition or disk:

.Trash-*

.nfs files are created when an open file is removed but is still being accessed:

.nfs*

Vim

Swap files:

[._]*.s[a-v][a-z]
[._]*.sw[a-p]
[._]s[a-rt-v][a-z]
[._]ss[a-gi-z]
[._]sw[a-p]

Session file:

Session.vim

Temporary files:

.netrwhist

Persistent undo files:

[._]*.un~