This repository has been archived on 2024-05-02. You can view files and clone it, but cannot push or open issues or pull requests.
home-manager-flake/modules/shell/git.nix

101 lines
2.8 KiB
Nix

{
config,
pkgs,
...
}: {
home = {
packages = with pkgs; [pre-commit];
};
programs = {
git = {
enable = true;
userName = "Patrick Neff";
userEmail = "odie86@gmail.com";
extraConfig = {
push = {
default = "matching";
};
core = {
autocrlf = "input";
#excludesFile = "${config.xdg.configHome}/git/ignore";
};
pull = {
rebase = false;
};
init = {
defaultBranch = "master";
};
};
attributes = [];
ignores = [
"# Created by https://www.toptal.com/developers/gitignore/api/vim,linux"
"# Edit at https://www.toptal.com/developers/gitignore?templates=vim,linux"
""
"### Linux ###"
"*~"
""
"# temporary files which can be created if a process still has a handle open of a deleted file"
".fuse_hidden*"
""
"# KDE directory preferences"
".directory"
""
"# 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"
"[._]*.s[a-v][a-z]"
"!*.svg # comment out if you don't need vector files"
"[._]*.sw[a-p]"
"[._]s[a-rt-v][a-z]"
"[._]ss[a-gi-z]"
"[._]sw[a-p]"
""
"# Session"
"Session.vim"
"Sessionx.vim"
""
"# Temporary"
".netrwhist"
"# Auto-generated tag files"
"tags"
"# Persistent undo"
"[._]*.un~"
""
"# End of https://www.toptal.com/developers/gitignore/api/vim,linux"
""
"# Created by https://www.toptal.com/developers/gitignore/api/nix"
"# Edit at https://www.toptal.com/developers/gitignore?templates=nix"
""
"/result"
""
"# End of https://www.toptal.com/developers/gitignore/api/nix"
""
"# Created by https://www.toptal.com/developers/gitignore/api/rust"
"# Edit at https://www.toptal.com/developers/gitignore?templates=rust"
# Created by https://www.toptal.com/developers/gitignore/api/direnv
"# Edit at https://www.toptal.com/developers/gitignore?templates=direnv"
""
"### direnv ###"
".direnv"
".envrc"
""
"# End of https://www.toptal.com/developers/gitignore/api/direnv"
"# Created by https://www.toptal.com/developers/gitignore/api/dotenv"
" # Edit at https://www.toptal.com/developers/gitignore?templates=dotenv"
""
"### dotenv ###"
"!.env.example"
".env"
".env.*"
""
"# End of https://www.toptal.com/developers/gitignore/api/dotenv"
];
};
};
}