Add zsh/shwordsplit compatibility for git_status_shortcuts

Necessary so that IFS works as expected
This commit is contained in:
Jonathan del Strother
2011-10-20 12:11:08 +01:00
parent a4d5006b5a
commit 7deb0c7909

View File

@@ -17,6 +17,7 @@
# 1 || staged, 2 || unmerged, 3 || unstaged, 4 || untracked # 1 || staged, 2 || unmerged, 3 || unstaged, 4 || untracked
# -------------------------------------------------------------------- # --------------------------------------------------------------------
git_status_shortcuts() { git_status_shortcuts() {
zsh_compat # Ensure shwordsplit is on for zsh
git_clear_vars git_clear_vars
# Run ruby script, store output # Run ruby script, store output
cmd_output=$(/usr/bin/env ruby "$scmbDir/lib/git/status_shortcuts.rb" $@) cmd_output=$(/usr/bin/env ruby "$scmbDir/lib/git/status_shortcuts.rb" $@)
@@ -32,6 +33,7 @@ git_status_shortcuts() {
# Print status # Print status
echo "$cmd_output" | grep -v '@@filelist@@::' echo "$cmd_output" | grep -v '@@filelist@@::'
zsh_reset # Reset zsh environment to default
} }