diff --git a/git/.gitconfig.local.symlink b/git/.gitconfig.local.symlink new file mode 100644 index 0000000..d1f88cf --- /dev/null +++ b/git/.gitconfig.local.symlink @@ -0,0 +1,5 @@ +# vim:set ft=toml sw=4 : + +[user] + name = Marley Rae + email = marley@punkfairie.net diff --git a/git/gitconfig.local.symlink.example b/git/.gitconfig.local.symlink.example similarity index 100% rename from git/gitconfig.local.symlink.example rename to git/.gitconfig.local.symlink.example diff --git a/git/.gitconfig.symlink b/git/.gitconfig.symlink new file mode 100644 index 0000000..eb50a48 --- /dev/null +++ b/git/.gitconfig.symlink @@ -0,0 +1,13 @@ +# vim:set ft=toml sw=4 : + +[alias] + prevision = "!f() { git checkout `git log --oneline $2 | awk -v commit=\"$1\" 'FNR == -commit+1 {print $1}'` $2; }; f" + nevermind = "reset --hard HEAD && git clean -df" + +[rebase] + autosquash = true +[merge] + tool = vimdiff +[mergetool] + keepBackup = false + hideResolved = true diff --git a/script/dot.sh b/script/dot.sh index 11b5282..d2b5832 100644 --- a/script/dot.sh +++ b/script/dot.sh @@ -130,7 +130,7 @@ setup_gitconfig() { cd "$dotfiles_dir" - if ! [[ -f $dotfiles_dir/git/gitconfig.local.symlink ]]; then + if ! [[ -f $dotfiles_dir/git/.gitconfig.local.symlink ]]; then print_title "Set up gitconfig" git_credential="cache" @@ -148,7 +148,7 @@ setup_gitconfig() sed -e "s/AUTHORNAME/$git_authorname/g" \ -e "s/AUTHOREMAIL/$git_authoremail/g" \ -e "s/GIT_CREDENTIAL_HELPER/$git_credential/g" \ - $dotfiles_dir/git/gitconfig.local.symlink.example > $dotfiles_dir/gitconfig.local.symlink + $dotfiles_dir/git/.gitconfig.local.symlink.example > $dotfiles_dir/.gitconfig.local.symlink print_result $? "gitconfig" fi