Skip to content

Commit 903cf91

Browse files
authored
Merge pull request #249 from djensenius/new-gitconfig-for-codespaces
New gitconfig for codespaces
2 parents 07664b2 + 9cbfe95 commit 903cf91

2 files changed

Lines changed: 65 additions & 4 deletions

File tree

gitconfig-github

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
[core]
2+
editor = nvim
3+
excludesfile = ~/.gitignore_local
4+
fsmonitor = true
5+
pager = delta
6+
untrackedCache = true
7+
8+
[include]
9+
path = ~/.config/delta/delta-themes.gitconfig
10+
11+
[pull]
12+
rebase = false
13+
14+
[codespaces-theme]
15+
hide-status = 1
16+
17+
[interactive]
18+
diffFilter = delta --color-only
19+
20+
[delta]
21+
features = side-by-side line-numbers decorations Catppuccin-mocha
22+
navigate = true
23+
24+
[gpg]
25+
program = /.codespaces/bin/gh-gpgsign
26+
27+
[init]
28+
defaultBranch = main
29+
30+
[credential]
31+
helper = /.codespaces/bin/gitcredential_github.sh
32+
33+
[user]
34+
name = David Jensenius
35+
email = david@jensenius.com
36+
37+
[filter "lfs"]
38+
clean = git-lfs clean -- %f
39+
smudge = git-lfs smudge -- %f
40+
process = git-lfs filter-process
41+
required = true
42+
43+
[push]
44+
default = current
45+
46+
[github]
47+
user = djensenius
48+
49+
[url "https://github.com/"]
50+
insteadOf = git@github.com:
51+
52+
[credential]
53+
helper = cache
54+
55+
56+
[alias]
57+
m = !git rev-parse --abbrev-ref origin/HEAD | cut -c8- | xargs -n 1 git checkout
58+
mp = !git rev-parse --abbrev-ref origin/HEAD | cut -c8- | xargs -n 1 git checkout && git pull origin $(git rev-parse --abbrev-ref HEAD)
59+
60+
[help]
61+
autocorrect = 20

install.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -139,10 +139,10 @@ function link_files() {
139139

140140
# Link core config files
141141
start_time=$(start_operation "Linking gitconfig")
142-
# if [ -e ~/.gitconfig ]; then
143-
# rm ~/.gitconfig
144-
# fi
145-
# ln -s $(pwd)/gitconfig ~/.gitconfig
142+
if [ -e ~/.gitconfig ]; then
143+
rm ~/.gitconfig
144+
fi
145+
ln -s $(pwd)/gitconfig-github ~/.gitconfig
146146
log_with_timing "Linking gitconfig" $start_time
147147

148148
start_time=$(start_operation "Linking gitignore_local")

0 commit comments

Comments
 (0)