config git au format Nix
This commit is contained in:
@@ -39,6 +39,37 @@ mkIf true {
|
||||
git = {
|
||||
enable = true;
|
||||
package = pkgs.gitFull;
|
||||
config = {
|
||||
# http://www.git-attitude.fr/2014/09/15/30-options-git-qui-gagnent-a-etre-connues/
|
||||
color = {
|
||||
diff = "auto";
|
||||
branch = "auto";
|
||||
interactive = "auto";
|
||||
pager = true;
|
||||
showbranch = "auto";
|
||||
status = "auto";
|
||||
};
|
||||
alias = {
|
||||
a = "add -p";
|
||||
br = "for-each-ref --sort=committerdate refs/heads/ --format='%(committerdate:short)\t%(authorname)\t%(refname:short)'";
|
||||
ci = "commit";
|
||||
co = "checkout";
|
||||
ff = "pull --ff-only";
|
||||
oops = "commit --amend --no-edit";
|
||||
# Show files ignored by git
|
||||
ignored = "ls-files -o -i --exclude-standard";
|
||||
ls = "ls-files";
|
||||
st = "status";
|
||||
# Logs
|
||||
lol = "log --graph --decorate --pretty=oneline --abbrev-commit";
|
||||
lola = "log --graph --decorate --pretty=oneline --abbrev-commit --all";
|
||||
not-pushed = "log --branches --not --remotes";
|
||||
};
|
||||
push.default = "simple";
|
||||
code.editor = "${pkgs.vim_configurable}/bin/vim";
|
||||
};
|
||||
lfs.enable = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user