diff --git a/git/.gitconfig b/git/.gitconfig index bfef090..e91a159 100644 --- a/git/.gitconfig +++ b/git/.gitconfig @@ -43,3 +43,5 @@ smudge = git-lfs smudge -- %f process = git-lfs filter-process required = true +[init] + defaultBranch = main diff --git a/git/.gitignore_global b/git/.gitignore_global index ab52217..5fe3fed 100644 --- a/git/.gitignore_global +++ b/git/.gitignore_global @@ -28,3 +28,6 @@ Thumbs.db Network Trash Folder Temporary Items .apdisk + +# Misc +.wakatime-project diff --git a/zsh/aliases.zsh b/zsh/aliases.zsh index 97eb4d1..0d9afb4 100644 --- a/zsh/aliases.zsh +++ b/zsh/aliases.zsh @@ -135,6 +135,13 @@ alias gist="hub gist create --open" alias ghnew="gh repo create" alias ghfork="gh repo fork" alias ghci="hub ci-status --verbose" +glall() { + # pull all remote branches + # https://stackoverflow.com/a/10312587 + for remote in `git branch -r`; do git branch --track ${remote#origin/} $remote; done + git fetch --all + git pull --all +} # # Docker @@ -172,9 +179,10 @@ make_hugo() { # parentheses lets us cd to Hugo path without changing our current location ( cd "$GOPATH/src/github.com/gohugoio/hugo" \ + && git checkout master \ + && mage uninstall \ && git pull origin master \ && git reset --hard HEAD \ - && git checkout master \ && mage -v hugo \ && HUGO_BUILD_TAGS=extended mage -v install )