feat: update gitcofig
This commit is contained in:
+6
-6
@@ -19,12 +19,12 @@ set -gx EDITOR vim
|
||||
|
||||
# alias
|
||||
# git
|
||||
abbr -a gitb "git branch --show-current | tr -d '\n' | pbcopy"
|
||||
abbr -a gci "golangci-lint run -c=~/.dotfile/.golangci.yml ./..."
|
||||
abbr -a gmt "go mod tidy"
|
||||
abbr -a gtc "go test -gcflags=all=-l -cover ./..."
|
||||
abbr -a swg "swag init -o docs -g "
|
||||
abbr -a sws "swagger serve -F=swagger"
|
||||
alias gitb="git branch --show-current | tr -d '\n' | pbcopy"
|
||||
alias gci="golangci-lint run -c=~/.dotfile/.golangci.yml ./..."
|
||||
alias gmt="go mod tidy"
|
||||
alias gtc="go test -gcflags=all=-l -cover ./..."
|
||||
alias swg="swag init -o docs -g "
|
||||
alias sws="swagger serve -F=swagger"
|
||||
|
||||
function gtr
|
||||
go test -gcflags=all=-l -v -run="$1"
|
||||
|
||||
+17
-2
@@ -4,14 +4,26 @@
|
||||
[core]
|
||||
autocrlf = input
|
||||
quotepath = false
|
||||
editor = /usr/local/bin/nvim
|
||||
editor = nvim
|
||||
excludesfile = ~/.dotfile/git/.gitignore
|
||||
[push]
|
||||
default = current
|
||||
[pull]
|
||||
rebase = false
|
||||
[color]
|
||||
status = auto
|
||||
diff = auto
|
||||
branch = auto
|
||||
interactive = auto
|
||||
grep = auto
|
||||
ui = auto
|
||||
[merge]
|
||||
tool = vimdiff
|
||||
tool = nvimdiff
|
||||
[difftool "nvimdiff"]
|
||||
cmd = nvim -d \"$LOCAL\" \"$REMOTE\"
|
||||
[mergetool "nvimdiff"]
|
||||
cmd = nvim -d \"$LOCAL\" \"$REMOTE\" -ancestor \"$BASE\" -merge \"$MERGED\"
|
||||
trustExitCode = true
|
||||
[includeIf "gitdir:~/workrepo/"]
|
||||
path = ~/.workgitconfig
|
||||
[branch]
|
||||
@@ -23,6 +35,9 @@
|
||||
st = status
|
||||
ap = add -p
|
||||
br = branch
|
||||
ba = branch -a
|
||||
bm = branch --merged
|
||||
bn = branch --no-merged
|
||||
pl = pull
|
||||
pt = push origin --tags
|
||||
merge2 = !sh -c '_CURRENT_BRANCH=$(git symbolic-ref --short HEAD) && git checkout $1 && git merge $_CURRENT_BRANCH && git checkout $_CURRENT_BRANCH' -
|
||||
|
||||
Reference in New Issue
Block a user