Skip to content

Commit

Permalink
[git] Setup git TUI
Browse files Browse the repository at this point in the history
I'm now using lazygit.
  • Loading branch information
francishamel committed Sep 9, 2024
1 parent 02f148e commit bc51079
Showing 1 changed file with 37 additions and 33 deletions.
70 changes: 37 additions & 33 deletions home-manager/modules/git.nix
Original file line number Diff line number Diff line change
@@ -1,43 +1,47 @@
{ config, ... }:

{
programs.git = {
userName = "Francis Hamel";
userEmail = "[email protected]";
aliases = {
ca = "commit --amend --no-edit";
cae = "commit --amend";
cf = "commit --fixup";
fp = "fetch --prune";
pfwl = "push --force-with-lease";
ri = "rebase --interactive";
};
enable = true;
extraConfig = {
init.defaultBranch = "main";
merge.conflictstyle = "diff3";
pull.rebase = true;
rebase = {
autoStash = true;
autosquash = true;
programs = {
git = {
userName = "Francis Hamel";
userEmail = "[email protected]";
aliases = {
ca = "commit --amend --no-edit";
cae = "commit --amend";
cf = "commit --fixup";
fp = "fetch --prune";
pfwl = "push --force-with-lease";
ri = "rebase --interactive";
};
enable = true;
extraConfig = {
init.defaultBranch = "main";
merge.conflictstyle = "diff3";
pull.rebase = true;
rebase = {
autoStash = true;
autosquash = true;
};
rerere.enabled = true;
};
rerere.enabled = true;
};
};

programs.gh = {
enable = true;
gitCredentialHelper.enable = false;
settings = {
aliases = {
"ic" = "issue create --web";
"id" = "issue develop $1 --checkout";
"il" = "issue list";
"prc" = "pr create --web --assignee @me";
"prv" = "pr view --web";
"rc" = "repo clone $1 ${config.home.homeDirectory}/src/$1";
gh = {
enable = true;
gitCredentialHelper.enable = false;
settings = {
aliases = {
"ic" = "issue create --web";
"id" = "issue develop $1 --checkout";
"il" = "issue list";
"prc" = "pr create --web --assignee @me";
"prv" = "pr view --web";
"rc" = "repo clone $1 ${config.home.homeDirectory}/src/$1";
};
git_protocol = "ssh";
};
git_protocol = "ssh";
};

lazygit.enable = true;
};
}

0 comments on commit bc51079

Please sign in to comment.