Paul Campbell <pcampb...@kemitix.net> writes:

> From: bibendi <bibe...@bk.ru>
>
> For each subtree listed in .gittrees perform a push or a pull.
>
> Signed-off-by: Paul Campbell <pcampb...@kemitix.net>
>
> Conflicts:
>       contrib/subtree/git-subtree.sh

The "Conflicts:" part is totally irrelevant.  Please remove.

> ---
>  contrib/subtree/git-subtree.sh | 25 ++++++++++++++++++++++---
>  1 file changed, 22 insertions(+), 3 deletions(-)
>
> diff --git a/contrib/subtree/git-subtree.sh b/contrib/subtree/git-subtree.sh
> index 1aff956..ddae56e 100755
> --- a/contrib/subtree/git-subtree.sh
> +++ b/contrib/subtree/git-subtree.sh
> @@ -12,6 +12,7 @@ git subtree add   --prefix=<prefix> <commit>
>  git subtree add   --prefix=<prefix> <repository> <commit>
>  git subtree merge --prefix=<prefix> <commit>
>  git subtree pull  --prefix=<prefix> <repository> <refspec...>
> +git subtree pull_all

Why isn't it "pull --all"?

>  git subtree push  --prefix=<prefix> <repository> <refspec...>

Where did "push_all" go?

> +cmd_pull_all()
> +{
> +    git config -f .gittrees -l | grep subtree | grep path | grep -o '=.*' | 
> grep -o '[^=].*' |

"grep -o" is not even in POSIX.  Besides, what is this trying to
parse?  Is it expected to match lines like

        path.subtree=trash

with this, or is it more like you only want something like this:

        subtree.over/there.path=foo

in which case you would want to read with something like

        sed -n -e 's/^subtree\...*\.path=\(.*\)/\1/p'

instead (modulo the usual caveat on $IFS whitespaces in path)?

> +        while read path; do
> +            git subtree pull -P $path master || exit $?
> +        done
> +}

I'd stop looking at this series myself at this step for now.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to