Files
.dotfile/script/git-init.sh
T
laily 1f6b042b26 feat: split git credential config by OS on Linux and macOS
Use includeIf so Linux prefers libsecret with cache fallback, while macOS keeps osxkeychain.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-25 11:04:15 +08:00

12 lines
197 B
Bash
Executable File

#!/bin/bash
echo 'Init git config'
src=$HOME/.gitconfig
if [ -f $src ]; then
mv $src $src.bak
fi
ln -s $HOME/.dotfile/git/.gitconfig $src
chmod +x "$HOME/.dotfile/git/git-credential-linux.sh"