-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Introduce config.nix, to avoid hardcoding (#125)
Add username, full name and email to it.
- Loading branch information
Showing
10 changed files
with
62 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
{ lib, ... }: | ||
{ | ||
options = { | ||
me = lib.mkOption { | ||
default = { }; | ||
type = lib.types.submodule { | ||
options = { | ||
username = lib.mkOption { | ||
type = lib.types.str; | ||
default = "runner"; | ||
description = "Your username as shown by `id -un`"; | ||
}; | ||
fullname = lib.mkOption { | ||
type = lib.types.str; | ||
default = "John Doe"; | ||
description = "Your full name for use in Git config"; | ||
}; | ||
email = lib.mkOption { | ||
type = lib.types.str; | ||
default = "[email protected]"; | ||
description = "Your email for use in Git config"; | ||
}; | ||
}; | ||
}; | ||
}; | ||
}; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,7 @@ | ||
{ ... }: | ||
{ flake, ... }: | ||
let | ||
inherit (flake.config) me; | ||
in | ||
{ | ||
home.shellAliases = { | ||
g = "git"; | ||
|
@@ -9,8 +12,8 @@ | |
programs = { | ||
git = { | ||
enable = true; | ||
userName = "John Doe"; | ||
userEmail = "[email protected]"; | ||
userName = me.fullname; | ||
userEmail = me.email; | ||
ignores = [ "*~" "*.swp" ]; | ||
aliases = { | ||
ci = "commit"; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -79,7 +79,7 @@ | |
# Open lazygit within nvim. | ||
{ | ||
action = "<cmd>LazyGit<CR>"; | ||
key = "<leader>gg"; | ||
key = "<leader>gg"; | ||
} | ||
]; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters