From: W Trevor King Date: Wed, 30 Nov 2011 15:30:09 +0000 (-0500) Subject: Fix option handling in run_on_all_repos(). X-Git-Tag: v0.3~36 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=abaf8e7a325d88bb9b7adb97f73accfc57c28f3a;p=dotfiles-framework.git Fix option handling in run_on_all_repos(). --- diff --git a/dotfiles.sh b/dotfiles.sh index 1e7b8a6..e637bf0 100755 --- a/dotfiles.sh +++ b/dotfiles.sh @@ -76,12 +76,13 @@ function get_selection() function run_on_all_repos() { COMMAND="${1}" + shift if [ -z "${REPO}" ]; then # run on all repositories for REPO in *; do if [ "${REPO}" = '*' ]; then break # no known repositories fi - "${COMMAND}" "${REPO}" || return 1 + "${COMMAND}" "${REPO}" "${@}" || return 1 done return fi @@ -728,7 +729,7 @@ function main() shift done if [ "${#}" -eq 0 ]; then - run_on_all_repos "${COMMAND}" "$OPTIONS[@]" || return 1 + run_on_all_repos "${COMMAND}" "${OPTIONS[@]}" || return 1 else maxargs "${0}" 1 "${@}" || return 1 "${COMMAND}" "${OPTIONS[@]}" "${1}" || return 1