summaryrefslogtreecommitdiffstatshomepage
path: root/dot_config/git
diff options
context:
space:
mode:
authorsommerfeld <sommerfeld@sommerfeld.dev>2026-09-17 15:05:36 +0100
committersommerfeld <sommerfeld@sommerfeld.dev>2026-09-17 15:05:36 +0100
commitaff435a0fb3a56b1d7b738c7dede363440884b3a (patch)
tree07acb41d37760aa169ee42dbeb69da3621cc7489 /dot_config/git
parenta7f74c1fa4b89c5829f5896842eb7248c820704c (diff)
downloaddotfiles-aff435a0fb3a56b1d7b738c7dede363440884b3a.tar.gz
dotfiles-aff435a0fb3a56b1d7b738c7dede363440884b3a.tar.bz2
dotfiles-aff435a0fb3a56b1d7b738c7dede363440884b3a.zip
Add the Canonical laptop profile and setup workflows
Diffstat (limited to 'dot_config/git')
-rw-r--r--dot_config/git/config.tmpl (renamed from dot_config/git/config)10
1 files changed, 10 insertions, 0 deletions
diff --git a/dot_config/git/config b/dot_config/git/config.tmpl
index 4237892..9987261 100644
--- a/dot_config/git/config
+++ b/dot_config/git/config.tmpl
@@ -1,7 +1,13 @@
[user]
+{{ if eq (default "host" (index . "machineRole")) "canonical" }}
+ email = {{ .workEmail | quote }}
+ name = {{ .workName | quote }}
+ signingkey = {{ .workSigningKey | quote }}
+{{ else }}
email = sommerfeld@sommerfeld.dev
name = sommerfeld
signingkey = 3298945F717C85F8
+{{ end }}
[push]
autoSetupRemote = true
followTags = true
@@ -9,8 +15,10 @@
[core]
whitespace = trailing-space,cr-at-eol
pager = delta
+{{ if ne (default "host" (index . "machineRole")) "canonical" }}
hooksPath = ~/.config/git/hooks
sshCommand = "ssh -i ~/.ssh/nym.pub"
+{{ end }}
[branch]
sort=-committerdate
[diff]
@@ -129,6 +137,7 @@
swd = switch -d
unstage = reset HEAD --
update=!git fetch && git merge --ff-only
+{{ if ne (default "host" (index . "machineRole")) "canonical" }}
[includeIf "gitdir:~/doxfiles/.git"]
path = config-personal
[includeIf "gitdir:~/dev/personal/"]
@@ -149,6 +158,7 @@
assume8bitEncoding = UTF-8
[credential "smtp://127.0.0.1:1016"]
helper = "!f() { test \"$1\" = get && printf 'password=%s\\n' \"$(pass show proton/bridge-smtp)\"; }; f"
+{{ end }}
[include]
; Machine-local overrides. Git silently skips this if the file is absent.
path = ~/.config/git/config.local