git,zsh:autoload: Move spull into own function

Move `git-track` into its own autoloadable function.

This way it is better maintainable as in one-liner format and brings the
possibility of having more complexity (e.g. for better portability).

By that it is also now executable as `git-spull` as well as `git spull`
as before.
This commit is contained in:
2022-05-14 16:04:35 +02:00
parent 0146956dd4
commit c22fcf5fce
2 changed files with 8 additions and 1 deletions

View File

@@ -15,7 +15,7 @@
flog = "!\"${XDG_CONFIG_HOME:-$HOME/.config}/zsh/autoload/git/glog\""
root = rev-parse --show-toplevel
signoff = "!\"${XDG_CONFIG_HOME:-$HOME/.config}/zsh/autoload/git/git-signoff\""
spull = "!__git_spull() { git pull \"$@\" && git submodule sync --recursive && git submodule update --init --recursive; }; __git_spull"
spull = "!\"${XDG_CONFIG_HOME:-$HOME/.config}/zsh/autoload/git/git-spull\""
track = "!\"${XDG_CONFIG_HOME:-$HOME/.config}/zsh/autoload/git/git-track\""
[blame]
date = short