{"thread":{"id":"19060","subject":"[PATCH] topgit tg push feature","startedAt":"2009-04-25T16:13:00Z","lastAt":"2009-05-13T11:42:07Z","messageCount":22,"participants":["Marc Weber","Bert Wesarg","Uwe Kleine-König","martin f krafft"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"112300","messageId":"20090425161300.GD19142@gmx.de","threadId":"19060","inReplyTo":null,"subject":"[PATCH] topgit tg push feature","fromName":"Marc Weber","fromEmail":"marco-oweber@gmx.de","sentAt":"2009-04-25T16:13:00Z","receivedAt":"2009-04-25T16:13:00Z","isPatch":true,"sender":{"key":"marco-oweber@gmx.de","avatar":null},"body":"The patch should apply cleanly on 9f685cd79.\nOr fetch it from branch t/tg-push at git://mawercer.de/topGit\n\nUntil now you've had two choices:\n\ngit push --all # pushing all top-bases and all other branches\nor run\ngit push t/foo top-bases/foo # + all deps manually\n\ntg push allows you to\na) push branch and its base, the branch you're on is used\nb) push branch its deps and their bases (adding -r)\n\nusing tg push remoteA remoteB you can push to multiple remote locations.\n\nMarc Weber\n\ncommit 2db369ff6dcfe9d5c4a9bab3eaf33c2a9b742f3d\nAuthor: Marc Weber <marco-oweber@gmx.de>\nDate:   Sat Apr 25 17:52:44 2009 +0200\n\n    add tg-push [-r] pushing the branch and its base\n    \n    -r: also push tgish dependencies\n    \n    Signed-off-by: Marc Weber <marco-oweber@gmx.de>\n\ndiff --git a/.gitignore b/.gitignore\nindex eb56446..2f6d991 100644\n--- a/.gitignore\n+++ b/.gitignore\n@@ -21,6 +21,8 @@\n /tg-import.txt\n /tg-remote\n /tg-remote.txt\n+/tg-push\n+/tg-push.txt\n /tg\n .*.swp\n \ndiff --git a/README b/README\nindex d2f095d..f90a7b3 100644\n--- a/README\n+++ b/README\n@@ -480,6 +480,13 @@ tg update\n \n \tTODO: tg update -a for updating all topic branches\n \n+tg push\n+~~~~~~~\n+\tgit push remote branch doesn't push the base.\n+        git push remote pushes all branches (and bases)\n+        You use tg push [-r] to push only the current branch [ and deps] with\n+        its base to a remote location.\n+\n TODO: tg rename\n \n \ndiff --git a/tg-push.sh b/tg-push.sh\nnew file mode 100644\nindex 0000000..0f8c964\n--- /dev/null\n+++ b/tg-push.sh\n@@ -0,0 +1,57 @@\n+#!/bin/sh\n+# TopGit - A different patch queue manager\n+# GPLv2\n+\n+recurse=\n+remotes=\n+\n+\n+## Parse options\n+\n+while [ -n \"$1\" ]; do\n+\targ=\"$1\"; shift\n+\tcase \"$arg\" in\n+\t-r)\n+\t\trecurse=1;;\n+\t*)\n+\t\tremotes=\"$remotes $arg\";;\n+\tesac\n+done\n+\n+if [ -z \"$remotes\" ]; then\n+\tremotes=\"$(git config topgit.remote 2>/dev/null)\"\n+fi\n+\n+if [ -z \"$remotes\" ]; then\n+\tdie \"no remote location given. Either add a remote as additional argument or set topgit.remote\"\n+fi\n+\n+name=\"$(git symbolic-ref HEAD | sed 's#^refs/heads/##')\"\n+ref_exists \"$name\" || die \"detached HEAD? Can't push that\"\n+\n+push_branch(){\n\n+\techo \"$_dep\" >> \"$to_be_pushed\"\n+\tbase=\"top-bases/$_dep\"\n+\tif ref_exists \"$base\"; then\n+\t\techo \"top-bases/$_dep\" >> \"$to_be_pushed\"\n+\telse\n+\t\techo \"warning, no base found $base\"\n+\tfi\n+}\n+\n+to_be_pushed=\"$(mktemp -t tg-depsfile.XXXXXX)\"\n+trap 'rm -rf \"$to_be_pushed\"' EXIT\n+\n+for remote in $remotes; do\n+\t: > $to_be_pushed # empty file\n+\n+\tif [ -n \"$recurse\" ]; then\n+\t\trecurse_deps push_branch \"$name\"\n+\tfi\n+\t_dep=\"$name\"\n+\t_dep_is_tgish=1\n+\tpush_branch\n+\techo git push $remote `cat $to_be_pushed`\n+\tgit push $remote `cat $to_be_pushed`\n+done\ndiff --git a/tg-push.txt b/tg-push.txt\nnew file mode 100644\nindex 0000000..de9b259\n--- /dev/null\n+++ b/tg-push.txt\n@@ -0,0 +1,3 @@\n+\tpush branch and base. If you also use -r all tgish dependencies\n+        will be pushed as well.\n+        Use tg push remoteA remoteB to push to remoteA and remoteB locations\n"},{"id":"112301","messageId":"20090425163447.GE19142@gmx.de","threadId":"19060","inReplyTo":"20090425161300.GD19142@gmx.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"Marc Weber","fromEmail":"marco-oweber@gmx.de","sentAt":"2009-04-25T16:34:47Z","receivedAt":"2009-04-25T16:34:47Z","isPatch":true,"sender":{"key":"marco-oweber@gmx.de","avatar":null},"body":"On Sat, Apr 25, 2009 at 06:13:00PM +0200, Marc Weber wrote:\n> The patch should apply cleanly on 9f685cd79.\n> Or fetch it from branch t/tg-push at git://mawercer.de/topGit\nUse the t/tg-push branch. I've fixed two small bugs. Sorry for this\ninconvinience.\n\nThanks\nMarc Weber\n"},{"id":"113026","messageId":"20090505093448.GC16524@gmx.de","threadId":"19060","inReplyTo":"20090425163447.GE19142@gmx.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"Marc Weber","fromEmail":"marco-oweber@gmx.de","sentAt":"2009-05-05T09:34:48Z","receivedAt":"2009-05-05T09:34:48Z","isPatch":true,"sender":{"key":"marco-oweber@gmx.de","avatar":null},"body":"updated version is availible:\nchanges:\n* push deps (even non-tgish) by default. You can switch off both by\n  --no-deps and --only-tgish\n* fixed remote check\n* adding --dry-run\n* no longer using temp file.\n\n\nThe patch should apply cleanly on 9f685cd79.\nYou can also get it by pulling from branch t/tg-push at git://mawercer.de/topGit\n\n\ncommit 30f6a7bc1d656249643f0c59e3095620990351d8\nAuthor: Marc Weber <marco-oweber@gmx.de>\nDate:   Tue May 5 11:31:53 2009 +0200\n\n    t/tg-push\n    \n    add tg-push  pushing the branch, its deps and their bases\n    \n    Usage: tg push [(--no-deps | --tgish-only)] remote*\n    \n    Signed-off-by: Marc Weber <marco-oweber@gmx.de>\n\ndiff --git a/.gitignore b/.gitignore\nindex eb56446..2f6d991 100644\n--- a/.gitignore\n+++ b/.gitignore\n@@ -21,6 +21,8 @@\n /tg-import.txt\n /tg-remote\n /tg-remote.txt\n+/tg-push\n+/tg-push.txt\n /tg\n .*.swp\n \ndiff --git a/README b/README\nindex d2f095d..290e883 100644\n--- a/README\n+++ b/README\n@@ -480,6 +480,19 @@ tg update\n \n \tTODO: tg update -a for updating all topic branches\n \n+tg push\n+~~~~~~~\n+\tUsage: tg push [(--no-deps | --tgish-only)] remote*\n+\t\n+\t$git push remote branch # this doesn't push the base.\n+\t$git push remote        # pushes all branches (and bases)\n+\tYou use\n+\n+\t$tg push remote\n+\tto push the current branch, its deps and their both tgish\n+\tand non-tgish deps. You may add --no-deps and or --tgish-only\n+\tto change this default behaviour\n+\n TODO: tg rename\n \n \ndiff --git a/tg-push.sh b/tg-push.sh\nnew file mode 100644\nindex 0000000..e79c19f\n--- /dev/null\n+++ b/tg-push.sh\n@@ -0,0 +1,68 @@\n+#!/bin/sh\n+# TopGit - A different patch queue manager\n+# GPLv2\n+\n+remotes=\n+\n+## Parse options see README\n+\n+recurse_deps=1\n+tgish_deps_only=\n+\n+while [ -n \"$1\" ]; do\n+\targ=\"$1\"; shift\n+\tcase \"$arg\" in\n+\t--no-deps)\n+\t\trecurse_deps=;;\n+\t--dry-run)\n+\t\tdry_run=1;;\n+\t--tgish-only)\n+\t\ttgish_deps_only=1;;\n+\t*)\n+\t\tremotes=\"$remotes $arg\";;\n+\tesac\n+done\n+\n+if [ -z \"$remotes\" ]; then\n+\tremotes=\"$(git config topgit.remote 2>/dev/null)\"\n+fi\n+\n+if [ -z \"$remotes\" ]; then\n+\tdie \"no remote location given. Either add a remote as additional argument or set topgit.remote\"\n+fi\n+\n+name=\"$(git symbolic-ref HEAD | sed 's#^refs/heads/##')\"\n+ref_exists \"$name\" || die \"detached HEAD? Can't push that\"\n+\n+push_branch(){\n+\t# don't push remotes, don't push non tg branches\n+\t[ -n \"${_dep##*/remotes/*}\" ] || [ -n \"$_dep_is_tgish\" ] || return 0\n+\t# if so desired omit non tgish deps\n+\t[ -z \"$tgish_deps_only\" ] || [ -n \"$_dep_is_tgish\" ] || return 0\n+\n+\techo \"$_dep\"\n+\tlocal base=\"top-bases/$_dep\"\n+\tif ref_exists \"$base\"; then\n+\t\techo \"top-bases/$_dep\"\n+\telse\n+\t\techo \"warning, no base found $base\" 1>&2\n+\tfi\n+}\n+\n+for remote in $remotes; do\n+\tlist=\"$(\n+\t\t# deps\n+\t\tif [ -n \"$recurse_deps\" ]; then\n+\t\t\trecurse_deps push_branch \"$name\"\n+\t\tfi\n+\t\t# current branch\n+\t\t_dep=\"$name\"\n+\t\t_dep_is_tgish=1\n+\t)\"\n+\techo \"pushing:\"; echo $list\n+\tif [ -n \"$dry_run\" ]; then\n+\t\techo git push $remote $list\n+\telse\n+\t\tgit push $remote $list\n+\tfi\n+done\n"},{"id":"113165","messageId":"20090507045904.GA2068@gmx.de","threadId":"19060","inReplyTo":"20090505093448.GC16524@gmx.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"Marc Weber","fromEmail":"marco-oweber@gmx.de","sentAt":"2009-05-07T04:59:04Z","receivedAt":"2009-05-07T04:59:04Z","isPatch":true,"sender":{"key":"marco-oweber@gmx.de","avatar":null},"body":"Uwe K,\n\nwhat do you think. Is there still much to change to include this patch into\nupstream?\n\nnew patch version. adding small comment saying that the two options\n--ne-deps and --tgish-only will seldomly used..\n\nSincerly\nMarc Weber\n\ncommit c1cff518e3f70e9bd6cb4f2119b86e506ab43776\nAuthor: Marc Weber <marco-oweber@gmx.de>\nDate:   Thu May 7 06:46:28 2009 +0200\n\n    t/tg-push\n    \n    add tg-push  pushing the branch, its deps and their bases\n    \n    Usage: tg push [(--no-deps | --tgish-only)] remote*\n    \n    Signed-off-by: Marc Weber <marco-oweber@gmx.de>\n\ndiff --git a/README b/README\nindex d2f095d..6f2b2bc 100644\n--- a/README\n+++ b/README\n@@ -480,6 +480,19 @@ tg update\n \n \tTODO: tg update -a for updating all topic branches\n \n+tg push\n+\tUsage: tg push [(--no-deps | --tgish-only)] remote*\n+\t\n+\t$git push remote branch # this doesn't push the base.\n+\t$git push remote        # pushes all branches (and bases)\n+\tYou use\n+\n+\t$tg push remote\n+\tto push the current branch, its deps and their both tgish\n+\tand non-tgish deps. You may add --no-deps and or --tgish-only\n+\tto change this default behaviour. Probably youn never want\n+\tto do this\n+\n TODO: tg rename\n \n \ndiff --git a/tg-push.sh b/tg-push.sh\nnew file mode 100644\nindex 0000000..49124e6\n--- /dev/null\n+++ b/tg-push.sh\n@@ -0,0 +1,69 @@\n+#!/bin/sh\n+# TopGit - A different patch queue manager\n+# GPLv2\n+\n+remotes=\n+\n+## Parse options see README\n+\n+recurse_deps=1\n+tgish_deps_only=\n+\n+while [ -n \"$1\" ]; do\n+\targ=\"$1\"; shift\n+\tcase \"$arg\" in\n+\t--no-deps)\n+\t\trecurse_deps=;;\n+\t--dry-run)\n+\t\tdry_run=1;;\n+\t--tgish-only)\n+\t\ttgish_deps_only=1;;\n+\t*)\n+\t\tremotes=\"$remotes $arg\";;\n+\tesac\n+done\n+\n+if [ -z \"$remotes\" ]; then\n+\tremotes=\"$(git config topgit.remote 2>/dev/null)\"\n+fi\n+\n+if [ -z \"$remotes\" ]; then\n+\tdie \"no remote location given. Either add a remote as additional argument or set topgit.remote\"\n+fi\n+\n+name=\"$(git symbolic-ref HEAD | sed 's#^refs/heads/##')\"\n+ref_exists \"$name\" || die \"detached HEAD? Can't push that\"\n+\n+push_branch(){\n+\t# don't push remotes\n+\t[ -z \"${_dep##refs/remotes/*}\" ] && return 0\n+\t# if so desired omit non tgish deps\n+\t[ -z \"$tgish_deps_only\" ] || [ -n \"$_dep_is_tgish\" ] || return 0\n+\n+\techo \"$_dep\"\n+\tlocal base=\"top-bases/$_dep\"\n+\tif ref_exists \"$base\"; then\n+\t\techo \"top-bases/$_dep\"\n+\telse\n+\t\techo \"warning, no base found $base\" 1>&2\n+\tfi\n+}\n+\n+for remote in $remotes; do\n+\tlist=\"$(\n+\t\t# deps\n+\t\tif [ -n \"$recurse_deps\" ]; then\n+\t\t\trecurse_deps push_branch \"$name\"\n+\t\tfi\n+\t\t# current branch\n+\t\t_dep=\"$name\"\n+\t\t_dep_is_tgish=1\n+\t\tpush_branch \"$name\"\n+\t)\"\n+\techo \"pushing:\"; echo $list\n+\tif [ -n \"$dry_run\" ]; then\n+\t\techo git push $remote $list\n+\telse\n+\t\tgit push $remote $list\n+\tfi\n+done\n"},{"id":"113167","messageId":"36ca99e90905062245w1ec78828ice5ed18161b6ec43@mail.gmail.com","threadId":"19060","inReplyTo":"20090507045904.GA2068@gmx.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"Bert Wesarg","fromEmail":"bert.wesarg@googlemail.com","sentAt":"2009-05-07T05:45:21Z","receivedAt":"2009-05-07T05:45:21Z","isPatch":true,"sender":{"key":"bert.wesarg@googlemail.com","avatar":"https://avatars.githubusercontent.com/u/111934?v=4"},"body":"On Thu, May 7, 2009 at 06:59, Marc Weber <marco-oweber@gmx.de> wrote:\n> Uwe K,\n>\n> what do you think. Is there still much to change to include this patch into\n> upstream?\nI think its a usefull tool, but I haven't tested it yet.\n\n>\n> new patch version. adding small comment saying that the two options\n> --ne-deps and --tgish-only will seldomly used..\n>\n> Sincerly\n> Marc Weber\n>\n> commit c1cff518e3f70e9bd6cb4f2119b86e506ab43776\n> Author: Marc Weber <marco-oweber@gmx.de>\n> Date:   Thu May 7 06:46:28 2009 +0200\n>\n>    t/tg-push\n>\n>    add tg-push  pushing the branch, its deps and their bases\n>\n>    Usage: tg push [(--no-deps | --tgish-only)] remote*\n>\n>    Signed-off-by: Marc Weber <marco-oweber@gmx.de>\n>\n> diff --git a/README b/README\n> index d2f095d..6f2b2bc 100644\n> --- a/README\n> +++ b/README\n> @@ -480,6 +480,19 @@ tg update\n>\n>        TODO: tg update -a for updating all topic branches\n>\n> +tg push\n> +       Usage: tg push [(--no-deps | --tgish-only)] remote*\nno need to repeat yourself. 'tg help push' will print the usage from\ntg-push first. And where is the --dry-run option?\n\n> +\n> +       $git push remote branch # this doesn't push the base.\n> +       $git push remote        # pushes all branches (and bases)\n> +       You use\n> +\n> +       $tg push remote\n> +       to push the current branch,\n> its deps and their both tgish and non-tgish deps.\nThis phrase needs rewording, what about: \"its deps, both their tgish\nand non-tgish ones.\"\n\n> You may add --no-deps and or --tgish-only\n> +       to change this default behaviour. Probably youn never want\n> +       to do this\nI think a \"use these only if you know what you are doing\" is better.\n\n> +\n>  TODO: tg rename\n>\n>\n> diff --git a/tg-push.sh b/tg-push.sh\n> new file mode 100644\n> index 0000000..49124e6\n> --- /dev/null\n> +++ b/tg-push.sh\n> @@ -0,0 +1,69 @@\n> +#!/bin/sh\n> +# TopGit - A different patch queue manager\n> +# GPLv2\n> +\n> +remotes=\n> +\n> +## Parse options see README\n> +\n> +recurse_deps=1\n> +tgish_deps_only=\n> +\n> +while [ -n \"$1\" ]; do\n> +       arg=\"$1\"; shift\n> +       case \"$arg\" in\n> +       --no-deps)\n> +               recurse_deps=;;\n> +       --dry-run)\n> +               dry_run=1;;\n> +       --tgish-only)\n> +               tgish_deps_only=1;;\n> +       *)\n> +               remotes=\"$remotes $arg\";;\n> +       esac\n> +done\nnow i see why you have the Usage: in the README. common practice is to\nprint the usage if an unknown option was given. see all the other\ntg-*.sh scripts.\n\n> +\n> +if [ -z \"$remotes\" ]; then\n> +       remotes=\"$(git config topgit.remote 2>/dev/null)\"\n> +fi\nHow effetcts the tg -r REMOTE option this command. Or more exactly why\ndoesn't have this option an effect here?\n\n> +\n> +if [ -z \"$remotes\" ]; then\n> +       die \"no remote location given. Either add a remote as additional argument or set topgit.remote\"\n> +fi\n> +\n> +name=\"$(git symbolic-ref HEAD | sed 's#^refs/heads/##')\"\n> +ref_exists \"$name\" || die \"detached HEAD? Can't push that\"\nthe common error message is: \"not a TopGit-controlled branch\".\n\n> +\n> +push_branch(){\n> +       # don't push remotes\n> +       [ -z \"${_dep##refs/remotes/*}\" ] && return 0\n> +       # if so desired omit non tgish deps\n> +       [ -z \"$tgish_deps_only\" ] || [ -n \"$_dep_is_tgish\" ] || return 0\n> +\n> +       echo \"$_dep\"\n> +       local base=\"top-bases/$_dep\"\n> +       if ref_exists \"$base\"; then\n> +               echo \"top-bases/$_dep\"\n> +       else\n> +               echo \"warning, no base found $base\" 1>&2\n> +       fi\n> +}\n> +\n> +for remote in $remotes; do\n> +       list=\"$(\n> +               # deps\n> +               if [ -n \"$recurse_deps\" ]; then\n> +                       recurse_deps push_branch \"$name\"\n> +               fi\n> +               # current branch\n> +               _dep=\"$name\"\n> +               _dep_is_tgish=1\n> +               push_branch \"$name\"\n> +       )\"\n> +       echo \"pushing:\"; echo $list\n> +       if [ -n \"$dry_run\" ]; then\n> +               echo git push $remote $list\n> +       else\n> +               git push $remote $list\n> +       fi\nwhy not pass the --dry-run option to git remote?\n\n> +done\n\nBert\n"},{"id":"113187","messageId":"20090507084355.GA11680@pengutronix.de","threadId":"19060","inReplyTo":"36ca99e90905062245w1ec78828ice5ed18161b6ec43@mail.gmail.com","subject":"Re: [PATCH] topgit tg push feature","fromName":"Uwe Kleine-König","fromEmail":"u.kleine-koenig@pengutronix.de","sentAt":"2009-05-07T08:43:55Z","receivedAt":"2009-05-07T08:43:55Z","isPatch":true,"sender":{"key":"u.kleine-koenig@pengutronix.de","avatar":"https://gravatar.com/avatar/354b5e3ceb2806a2f1e1e382ac29ddbdad18288654da62b61eb13583a857eee7?d=mp&s=160"},"body":"Hi Marc, hi Bert,\n\n\nOn Thu, May 07, 2009 at 07:45:21AM +0200, Bert Wesarg wrote:\n> On Thu, May 7, 2009 at 06:59, Marc Weber <marco-oweber@gmx.de> wrote:\n> > Uwe K,\n> >\n> > what do you think. Is there still much to change to include this patch into\n> > upstream?\n> I think its a usefull tool, but I haven't tested it yet.\nBert, thanks for your review.\n \n> > new patch version. adding small comment saying that the two options\n> > --ne-deps and --tgish-only will seldomly used..\n> >\n> > Sincerly\n> > Marc Weber\n> >\n> > commit c1cff518e3f70e9bd6cb4f2119b86e506ab43776\n> > Author: Marc Weber <marco-oweber@gmx.de>\n> > Date:   Thu May 7 06:46:28 2009 +0200\n> >\n> >    t/tg-push\n> >\n> >    add tg-push  pushing the branch, its deps and their bases\n> >\n> >    Usage: tg push [(--no-deps | --tgish-only)] remote*\n> >\n> >    Signed-off-by: Marc Weber <marco-oweber@gmx.de>\n> >\n> > diff --git a/README b/README\n> > index d2f095d..6f2b2bc 100644\n> > --- a/README\n> > +++ b/README\n> > @@ -480,6 +480,19 @@ tg update\n> >\n> >        TODO: tg update -a for updating all topic branches\n> >\n> > +tg push\n> > +       Usage: tg push [(--no-deps | --tgish-only)] remote*\n> no need to repeat yourself. 'tg help push' will print the usage from\n> tg-push first. And where is the --dry-run option?\n> \n> > +       $git push remote branch # this doesn't push the base.\n> > +       $git push remote        # pushes all branches (and bases)\n> > +       You use\n> > +\n> > +       $tg push remote\n> > +       to push the current branch,\n> > its deps and their both tgish and non-tgish deps.\n> This phrase needs rewording, what about: \"its deps, both their tgish\n> and non-tgish ones.\"\nI'd like to have a bit more prose.  Something like:\n\n\ttg push\n\t~~~~~~~\n\t\tpushes a TopGit-controlled topic branch to a remote\n\t\trepository.  By default the remote gets all dependencies\n\t\t(both tgish and non-tgish) and bases pushed to.\n\n> > --- /dev/null\n> > +++ b/tg-push.sh\n> > @@ -0,0 +1,69 @@\n> > +#!/bin/sh\n> > +# TopGit - A different patch queue manager\n> > +# GPLv2\n> > +\n> > +remotes=\n> > +\n> > +## Parse options see README\n> > +\n> > +recurse_deps=1\n> > +tgish_deps_only=\n> > +\n> > +while [ -n \"$1\" ]; do\n> > +       arg=\"$1\"; shift\n> > +       case \"$arg\" in\n> > +       --no-deps)\n> > +               recurse_deps=;;\n> > +       --dry-run)\n> > +               dry_run=1;;\n> > +       --tgish-only)\n> > +               tgish_deps_only=1;;\n> > +       *)\n> > +               remotes=\"$remotes $arg\";;\n> > +       esac\n> > +done\n> now i see why you have the Usage: in the README. common practice is to\n> print the usage if an unknown option was given. see all the other\n> tg-*.sh scripts.\nack\n \n> > +\n> > +if [ -z \"$remotes\" ]; then\n> > +       remotes=\"$(git config topgit.remote 2>/dev/null)\"\n> > +fi\n> How effetcts the tg -r REMOTE option this command. Or more exactly why\n> doesn't have this option an effect here?\nack\n \n> > +\n> > +if [ -z \"$remotes\" ]; then\n> > +       die \"no remote location given. Either add a remote as additional argument or set topgit.remote\"\n> > +fi\n> > +\n> > +name=\"$(git symbolic-ref HEAD | sed 's#^refs/heads/##')\"\n> > +ref_exists \"$name\" || die \"detached HEAD? Can't push that\"\n> the common error message is: \"not a TopGit-controlled branch\".\n> \n> > +\n> > +push_branch(){\n> > +       # don't push remotes\n> > +       [ -z \"${_dep##refs/remotes/*}\" ] && return 0\nmaybe extend the comment to something like:\n\n\t# if a remote is used ('topgit.remote' configuration variable or\n\t# tg -r $remote, a tg-base implicitly depends on\n\t# refs/remotes/$remote/top-bases/$_dep.  Don't push these.\n\nYou could even test if this is a dependency as described in this\ncomment.  Didn't test it, but something like\n\n\ttest \"x$_dep\" = \"xrefs/remotes/$base_remote/top-bases/$_name\"\n\ncould do the trick.\n\n> > +       # if so desired omit non tgish deps\n> > +       [ -z \"$tgish_deps_only\" ] || [ -n \"$_dep_is_tgish\" ] || return 0\nI've always problems to understand these constructs.  Are these any\nbetter than\n\n\tif test ...; then\n\t\treturn 0\n\tfi\n\n?  And I think it's more readable to use\n\n\ttgish_deps_only=false\n\n\t...\n\t\t--tgish-only)\n\t\t\ttgish_deps_only=true;;\n\n\t...\n\n\tif $tgish_deps_only; then\n\n\t\t...\n\n\tfi\n\n.  (OK, I have to admit, that these constructs are used everywhere in\ntopgit, but I'm not happy with these either.)\n\n\n> > +       echo \"$_dep\"\n> > +       local base=\"top-bases/$_dep\"\n> > +       if ref_exists \"$base\"; then\n> > +               echo \"top-bases/$_dep\"\n> > +       else\n> > +               echo \"warning, no base found $base\" 1>&2\n> > +       fi\nmmh, I wonder why you need to do the top-bases explicitly.  recurse_deps\ndoesn't that for you?\n\n> > +}\n> > +\n> > +for remote in $remotes; do\n> > +       list=\"$(\n> > +               # deps\n> > +               if [ -n \"$recurse_deps\" ]; then\n> > +                       recurse_deps push_branch \"$name\"\n> > +               fi\n> > +               # current branch\n> > +               _dep=\"$name\"\n> > +               _dep_is_tgish=1\n> > +               push_branch \"$name\"\n> > +       )\"\n> > +       echo \"pushing:\"; echo $list\n> > +       if [ -n \"$dry_run\" ]; then\n> > +               echo git push $remote $list\n> > +       else\n> > +               git push $remote $list\n> > +       fi\n> why not pass the --dry-run option to git remote?\ns/remote/push/\n \nBest regards\nUwe\n\n-- \nPengutronix e.K.                              | Uwe Kleine-König            |\nIndustrial Linux Solutions                    | http://www.pengutronix.de/  |\n"},{"id":"113200","messageId":"36ca99e90905070250l656f8879g87eb27c09db2cd42@mail.gmail.com","threadId":"19060","inReplyTo":"20090507084355.GA11680@pengutronix.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"Bert Wesarg","fromEmail":"bert.wesarg@googlemail.com","sentAt":"2009-05-07T09:50:27Z","receivedAt":"2009-05-07T09:50:27Z","isPatch":true,"sender":{"key":"bert.wesarg@googlemail.com","avatar":"https://avatars.githubusercontent.com/u/111934?v=4"},"body":"2009/5/7 Uwe Kleine-König <u.kleine-koenig@pengutronix.de>:\n> Hi Marc, hi Bert,\n>> > +       # if so desired omit non tgish deps\n>> > +       [ -z \"$tgish_deps_only\" ] || [ -n \"$_dep_is_tgish\" ] || return 0\n> I've always problems to understand these constructs.  Are these any\n> better than\n>\n>        if test ...; then\n>                return 0\n>        fi\n>\n> ?  And I think it's more readable to use\n>\n>        tgish_deps_only=false\n>\n>        ...\n>                --tgish-only)\n>                        tgish_deps_only=true;;\n>\n>        ...\n>\n>        if $tgish_deps_only; then\n>\n>                ...\n>\n>        fi\n>\n> .  (OK, I have to admit, that these constructs are used everywhere in\n> topgit, but I'm not happy with these either.)\nI also like the true/false style, its also useable with the current 'scheme':\n\n       $tgish_deps_only && ...\n"},{"id":"113397","messageId":"20090509103625.GC13344@lapse.rw.madduck.net","threadId":"19060","inReplyTo":"36ca99e90905070250l656f8879g87eb27c09db2cd42@mail.gmail.com","subject":"Re: [PATCH] topgit tg push feature","fromName":"martin f krafft","fromEmail":"madduck@madduck.net","sentAt":"2009-05-09T10:36:25Z","receivedAt":"2009-05-09T10:36:25Z","isPatch":true,"sender":{"key":"madduck@madduck.net","avatar":null},"body":"Marc, can you send an updated patch?\n\nI would be interested in investigating this feature, which could be\nvery useful in the context of the discussion in\nhttp://bugs.debian.org/505303 and\nhttp://marc.info/?l=vcs-pkg&m=124186459805688&w=2 about deleting\nbranches, specifically preventing their re-publication. tg-push\nshould allow us to get rid of the push refspecs in the repo config\nand return to the default of ':', thus preventing a normal push from\npushing tips not already present remotely.\n\nI'd still prefer tg-push integrated in git-push (e.g. by way of\n\"related branches\" which are always pushed alongside a normal\nbranch), but that's not going to happen any time soon, I am sure...\n\n-- \nmartin | http://madduck.net/ | http://two.sentenc.es/\n \nwindoze nt crashed.\ni am the blue screen of death.\nno one hears your screams.\n \nspamtraps: madduck.bogus@madduck.net\n"},{"id":"113420","messageId":"20090509190910.GA9655@gmx.de","threadId":"19060","inReplyTo":"20090509103625.GC13344@lapse.rw.madduck.net","subject":"Re: [PATCH] topgit tg push feature","fromName":"Marc Weber","fromEmail":"marco-oweber@gmx.de","sentAt":"2009-05-09T19:09:10Z","receivedAt":"2009-05-09T19:09:10Z","isPatch":true,"sender":{"key":"marco-oweber@gmx.de","avatar":null},"body":"On Sat, May 09, 2009 at 12:36:25PM +0200, martin f krafft wrote:\n> Marc, can you send an updated patch?\nYes, I'll provide one ASAP (tonight or tomorrow). You already can apply\nthe patch and use it (So do I).\nThanks for all the feedback. I have some other work to do first, sry.\nIf I'm not fast enough: the public repo is read/write. You may just\ncommit as well.\n\ncu all!\nMarc Weber\n"},{"id":"113511","messageId":"20090511032813.GA15540@gmx.de","threadId":"19060","inReplyTo":"20090509190910.GA9655@gmx.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"Marc Weber","fromEmail":"marco-oweber@gmx.de","sentAt":"2009-05-11T03:28:13Z","receivedAt":"2009-05-11T03:28:13Z","isPatch":true,"sender":{"key":"marco-oweber@gmx.de","avatar":null},"body":"Feedback to Berts reply:\n\n  > tg-push first. And where is the --dry-run option?\n  fixed: added -h|--help option\n\n  >This phrase needs rewording, what about: \"its deps, both their tgish\n  >and non-tgish ones.\"\n  fixed, used Uwes text.\n\n  It looks like this now:\n\n          $tg push remote\n          to push the current branch, its deps and, both their tgish\n          and non-tgish ones.  You may add --no-deps and or --tgish-only\n          to change this default behaviour. Use these only if you know what you\n          are doing. They are only present for the sake of completeness.\n\n\n  >now i see why you have the Usage: in the README. common practice is to\n  >print the usage if an unknown option was given. see all the other\n  >tg-*.sh scripts.\n  fixed: see -h|--help above. tg export lists the Usage as well in the README. (-> other topic)\n\n\n\n  >How effetcts the tg -r REMOTE option this command. Or more exactly why\n  >doesn't have this option an effect here?\n  laziness. I thought about that myself. Its fixed now. Usage looks like this:\n\n    Usage: tg push [(--dry-run | --no-deps | --tgish-only)] [-r \"remote remote2\"]* branch*\n\n\n  > the common error message is: \"not a TopGit-controlled branch\".\n  :-) The point about this is: You can use\n    $tg push -r \"remote1 remote2\" non-tgish-branch1 non-tgish-branch2.\n  tg push will note that it can't find remotes but it'll push those branches.\n  So you can \"abuse\" tg push to push normal branches to multiple remote\n  locations.\n\n  > why not pass the --dry-run option to git remote?\n  git remote -> git push:\n  I added --dry-run so that I can see the list of branches which would be pushed\n  if I had not used --dry-run. It isn't that important that's why I missed adding\n  it to Usage as well.\n\n  \nFeedback to Uwe Klein Koenigs mail:\n\n  > I'd like to have a bit more prose.  Something like:\n  fixed/misus\n\n\n  > maybe extend the comment to something like:\n\n  >         # if a remote is used ('topgit.remote' configuration variable or\n  >         # tg -r $remote, a tg-base implicitly depends on\n  >         # refs/remotes/$remote/top-bases/$_dep.  Don't push these.\n\n  > You could even test if this is a dependency as described in this\n  > comment.  Didn't test it, but something like\n\n  >         test \"x$_dep\" = \"xrefs/remotes/$base_remote/top-bases/$_name\"\n\n  > could do the trick.\n\n  I've extended the recurse_deps function reading from the global var\n  no_remotes now. It's still ugly but less verbose and more intuitive than\n  adding long comments\n\n\n\n  > > +       [ -z \"$tgish_deps_only\" ] || [ -n \"$_dep_is_tgish\" ] || return 0\n  >I've always problems to understand these constructs.  Are these any\n  >better than\n  ... :-) *lol* You proposed using them :-)\n  I do have a vary hard time reading writing them as well.\n  I have to use boolean algebra to wrap my head around those constructs.\n\n\n  > > +       echo \"$_dep\"\n  > > +       local base=\"top-bases/$_dep\"\n  > > +       if ref_exists \"$base\"; then\n  > > +               echo \"top-bases/$_dep\"\n  > > +       else\n  > > +               echo \"warning, no base found $base\" 1>&2\n  > > +       fi\n  >mmh, I wonder why you need to do the top-bases explicitly.  recurse_deps\n  >doesn't that for you?\n  Have a closer look at that function, please:\n    \"\n      has_remote \"top-bases/$_name\" && [ -z \"$no_remotes\" ] &&\n              echo \"refs/remotes/$base_remote/top-bases/$_name\" >>\"$_depsfile\"\n      [..]\n      ref_exists \"refs/top-bases/$_dep\"  ||\n    \"\n  are all occurrences of top-bases. And both only do checks (or push remotes)\n\n\n\nFeedback to Berts 2nd reply:\n\n  >I also like the true/false style, its also useable with the current 'scheme':\n  >    $tgish_deps_only && ...  \n  great idea. true/false are sh builtins. adopted. I still prefer\n  [ foo -a bar ]; or [ foo -o bar ]; for readability.\n\nSincerly\nMarc Weber\n\ncommit cdab940eefc0a56e0daa8b270bace1aba00a3b57\nAuthor: Marc Weber <marco-oweber@gmx.de>\nDate:   Mon May 11 05:25:40 2009 +0200\n\n    t/tg-push\n    \n    add tg-push  pushing the branch, its deps and their bases\n    \n    Signed-off-by: Marc Weber <marco-oweber@gmx.de>\n\ndiff --git a/.gitignore b/.gitignore\nindex eb56446..2f6d991 100644\n--- a/.gitignore\n+++ b/.gitignore\n@@ -21,6 +21,8 @@\n /tg-import.txt\n /tg-remote\n /tg-remote.txt\n+/tg-push\n+/tg-push.txt\n /tg\n .*.swp\n \ndiff --git a/README b/README\nindex d2f095d..495c70b 100644\n--- a/README\n+++ b/README\n@@ -480,6 +480,12 @@ tg update\n \n \tTODO: tg update -a for updating all topic branches\n \n+tg push\n+~~~~~~~\n+\tpushes a TopGit-controlled topic branch to a remote\n+\trepository.  By default the remote gets all dependencies\n+\t(both tgish and non-tgish) and bases pushed to.\n+\n TODO: tg rename\n \n \ndiff --git a/tg-push.sh b/tg-push.sh\nnew file mode 100644\nindex 0000000..0fa7854\n--- /dev/null\n+++ b/tg-push.sh\n@@ -0,0 +1,82 @@\n+#!/bin/sh\n+# TopGit - A different patch queue manager\n+# GPLv2\n+\n+remotes=\n+\n+## Parse options see README\n+\n+recurse_deps=true\n+tgish_deps_only=false\n+dry_run=false\n+\n+while [ -n \"$1\" ]; do\n+\targ=\"$1\"; shift\n+\tcase \"$arg\" in\n+\t--no-deps)\n+\t\trecurse_deps=false;;\n+\t--dry-run)\n+\t\tdry_run=true;;\n+\t--tgish-only)\n+\t\ttgish_deps_only=true;;\n+\t-h|--help)\n+\t\techo \"Usage: tg push [(--dry-run | --no-deps | --tgish-only)] [-r \"remote remote2\"]* branch*\"\n+\t\texit 1;;\n+\t-r)\n+\t\tremotes=\"$remotes $1\"\n+\t\tshift\n+\t\t;;\n+\t*)\n+\t\tbranches=\"$branches $arg\";;\n+\tesac\n+done\n+\n+if [ -z \"$remotes\" ]; then\n+\tremotes=\"$(git config topgit.remote 2>/dev/null)\"\n+fi\n+\n+if [ -z \"$remotes\" ]; then\n+\tdie \"no remote location given. Either use -r remote argument or set topgit.remote\"\n+fi\n+\n+if [ -z \"$branches\" ]; then\n+\tbranches=\"$(git symbolic-ref HEAD | sed 's#^refs/heads/##')\"\n+fi\n+\n+for name in $branches; do\n+\tref_exists \"$name\" || die \"detached HEAD? Can't push that\"\n+done\n+\n+push_branch(){\n+\t# if so desired omit non tgish deps\n+\t $tgish_deps_only && [ -z \"$_dep_is_tgish\" ] && return 0\n+\n+\techo \"$_dep\"\n+\tlocal base=\"top-bases/$_dep\"\n+\tif ref_exists \"$base\"; then\n+\t\techo \"top-bases/$_dep\"\n+\telse\n+\t\techo \"warning, no base found $base\" 1>&2\n+\tfi\n+}\n+\n+for remote in $remotes; do\n+\tfor name in $branches; do\n+\t\tlist=\"$(\n+\t\t\t# deps\n+\t\t\tif $recurse_deps; then\n+\t\t\t\tno_remotes=1 recurse_deps push_branch \"$name\"\n+\t\t\tfi\n+\t\t\t# current branch\n+\t\t\t_dep=\"$name\"\n+\t\t\t_dep_is_tgish=1\n+\t\t\tpush_branch \"$name\"\n+\t\t)\"\n+\t\techo \"pushing:\"; echo $list\n+\t\tif $dry_run; then\n+\t\t\techo git push $remote $list\n+\t\telse\n+\t\t\tgit push $remote $list\n+\t\tfi\n+\tdone\n+done\ndiff --git a/tg.sh b/tg.sh\nindex 0804f73..94f38f4 100644\n--- a/tg.sh\n+++ b/tg.sh\n@@ -136,6 +136,7 @@ branch_annihilated()\n # of the whole function.\n # If recurse_deps() hits missing dependencies, it will append\n # them to space-separated $missing_deps list and skip them.\n+# set no_remotes to any value to omit remote dependencies (-> tg push)\n recurse_deps()\n {\n \t_cmd=\"$1\"; shift\n@@ -145,9 +146,8 @@ recurse_deps()\n \t_depsfile=\"$(mktemp -t tg-depsfile.XXXXXX)\"\n \t# Check also our base against remote base. Checking our head\n \t# against remote head has to be done in the helper.\n-\tif has_remote \"top-bases/$_name\"; then\n+\thas_remote \"top-bases/$_name\" && [ -z \"$no_remotes\" ] &&\n \t\techo \"refs/remotes/$base_remote/top-bases/$_name\" >>\"$_depsfile\"\n-\tfi\n \n \t# if the branch was annihilated, there exists no .topdeps file\n \tif ! branch_annihilated \"$_name\"; then\n"},{"id":"113519","messageId":"20090511072507.GA24235@lapse.rw.madduck.net","threadId":"19060","inReplyTo":"20090511032813.GA15540@gmx.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"martin f krafft","fromEmail":"madduck@madduck.net","sentAt":"2009-05-11T07:25:07Z","receivedAt":"2009-05-11T07:25:07Z","isPatch":true,"sender":{"key":"madduck@madduck.net","avatar":null},"body":"also sprach Marc Weber <marco-oweber@gmx.de> [2009.05.11.0528 +0200]:\n>   >I also like the true/false style, its also useable with the current 'scheme':\n>   >    $tgish_deps_only && ...  \n>   great idea. true/false are sh builtins. adopted. I still prefer\n>   [ foo -a bar ]; or [ foo -o bar ]; for readability.\n\nThe patch looks good, I am going to test it now, I hope.\n\nQuick comment: -a and -o are not POSIX-compliant, use [ \"$foo\" ] ||\n[ \"$bar\" ] instead.\n\n-- \nmartin | http://madduck.net/ | http://two.sentenc.es/\n \nthe early bird may get the worm,\nbut the second mouse gets the cheese in the trap.\n \nspamtraps: madduck.bogus@madduck.net\n"},{"id":"113524","messageId":"20090511074731.GA30271@lapse.rw.madduck.net","threadId":"19060","inReplyTo":"20090511032813.GA15540@gmx.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"martin f krafft","fromEmail":"madduck@madduck.net","sentAt":"2009-05-11T07:47:31Z","receivedAt":"2009-05-11T07:47:31Z","isPatch":true,"sender":{"key":"madduck@madduck.net","avatar":null},"body":"also sprach Marc Weber <marco-oweber@gmx.de> [2009.05.11.0528 +0200]:\n> commit cdab940eefc0a56e0daa8b270bace1aba00a3b57\n> Author: Marc Weber <marco-oweber@gmx.de>\n> Date:   Mon May 11 05:25:40 2009 +0200\n> \n>     t/tg-push\n>     \n>     add tg-push  pushing the branch, its deps and their bases\n>     \n>     Signed-off-by: Marc Weber <marco-oweber@gmx.de>\n\nI tested this feature and it seems to work quite nicely. I have\na couple of minor remarks, but otherwise am ready to sign this off\nand include it upstream.\n\nAs soon as this feature is there, we need to disable to push\nrefspecs installed by tg-remote, and also probably add a warning to\nthe hook in case they are present; those are evil.\n\n> +\t-h|--help)\n> +\t\techo \"Usage: tg push [(--dry-run | --no-deps | --tgish-only)] [-r \"remote remote2\"]* branch*\"\n> +\t\texit 1;;\n\n--help should not exit non-zero, because if you ask for --help and\nit prints it, that's not an error.\n\n> +if [ -z \"$remotes\" ]; then\n> +\tremotes=\"$(git config topgit.remote 2>/dev/null)\"\n> +fi\n\nThis configuration key was news to me, but only because I usually\nrun tg-remote without --populate, in which case it is not added.\nThis is probably a bug in tg-remote and should be fixed alongside\nthe push refspec removal.\n\n> +\t\techo \"pushing:\"; echo $list\n> +\t\tif $dry_run; then\n> +\t\t\techo git push $remote $list\n> +\t\telse\n> +\t\t\tgit push $remote $list\n> +\t\tfi\n\ngit-push has --dry-run, why not use that?\n\n-- \nmartin | http://madduck.net/ | http://two.sentenc.es/\n \ndue to lack of interest tomorrow has been cancelled.\n \nspamtraps: madduck.bogus@madduck.net\n"},{"id":"113578","messageId":"20090511195532.GA28340@pengutronix.de","threadId":"19060","inReplyTo":"20090511032813.GA15540@gmx.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"Uwe Kleine-König","fromEmail":"u.kleine-koenig@pengutronix.de","sentAt":"2009-05-11T19:55:32Z","receivedAt":"2009-05-11T19:55:32Z","isPatch":true,"sender":{"key":"u.kleine-koenig@pengutronix.de","avatar":"https://gravatar.com/avatar/354b5e3ceb2806a2f1e1e382ac29ddbdad18288654da62b61eb13583a857eee7?d=mp&s=160"},"body":"Hi Marc,\n\njust some random nitpicks on top of your patch:\n\ndiff --git a/tg-push.sh b/tg-push.sh\nindex 0fa7854..8897a18 100644\n--- a/tg-push.sh\n+++ b/tg-push.sh\n@@ -8,7 +8,7 @@ remotes=\n \n recurse_deps=true\n tgish_deps_only=false\n-dry_run=false\n+dry_run=\n \n while [ -n \"$1\" ]; do\n \targ=\"$1\"; shift\n@@ -16,11 +16,11 @@ while [ -n \"$1\" ]; do\n \t--no-deps)\n \t\trecurse_deps=false;;\n \t--dry-run)\n-\t\tdry_run=true;;\n+\t\tdry_run=\"--dry-run\";;\n \t--tgish-only)\n \t\ttgish_deps_only=true;;\n \t-h|--help)\n-\t\techo \"Usage: tg push [(--dry-run | --no-deps | --tgish-only)] [-r \"remote remote2\"]* branch*\"\n+\t\techo \"Usage: tg push [--dry-run] [--no-deps] [--tgish-only] [-r \"remote remote2\"]* branch*\"\n \t\texit 1;;\n \t-r)\n \t\tremotes=\"$remotes $1\"\n@@ -44,12 +44,12 @@ if [ -z \"$branches\" ]; then\n fi\n \n for name in $branches; do\n-\tref_exists \"$name\" || die \"detached HEAD? Can't push that\"\n+\tref_exists \"$name\" || die \"detached HEAD? Can't push $name\"\n done\n \n push_branch(){\n \t# if so desired omit non tgish deps\n-\t $tgish_deps_only && [ -z \"$_dep_is_tgish\" ] && return 0\n+\t$tgish_deps_only && [ -z \"$_dep_is_tgish\" ] && return 0\n \n \techo \"$_dep\"\n \tlocal base=\"top-bases/$_dep\"\n@@ -73,10 +73,6 @@ for remote in $remotes; do\n \t\t\tpush_branch \"$name\"\n \t\t)\"\n \t\techo \"pushing:\"; echo $list\n-\t\tif $dry_run; then\n-\t\t\techo git push $remote $list\n-\t\telse\n-\t\t\tgit push $remote $list\n-\t\tfi\n+\t\tgit push $dry_run \"$remote\" $list\n \tdone\n done\n-- \n1.6.2.4\n\nIt's untested, but I think it should be enough if it is eyeballed by\nsomeone else.\n\nBest regards\nUwe\n\n-- \nPengutronix e.K.                              | Uwe Kleine-König            |\nIndustrial Linux Solutions                    | http://www.pengutronix.de/  |\n"},{"id":"113589","messageId":"20090511210614.GA6118@gmx.de","threadId":"19060","inReplyTo":"20090511195532.GA28340@pengutronix.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"Marc Weber","fromEmail":"marco-oweber@gmx.de","sentAt":"2009-05-11T21:06:14Z","receivedAt":"2009-05-11T21:06:14Z","isPatch":true,"sender":{"key":"marco-oweber@gmx.de","avatar":null},"body":"Thanks to Bert Wesarg, Uwe Kleine-König and Martin f Krafft the\npatch is finally ready to be comitted (?) I included ukleineks last\nnitpicks.\n\nukleinek, usage line: remote2 = just another remote location.\n\nMarc Weber\n\ncommit 0bfa198a3cae72d75ca1311bb7a8d495ca2b42cc\nAuthor: Marc Weber <marco-oweber@gmx.de>\nDate:   Mon May 11 23:04:20 2009 +0200\n\n    add tg-push pushing the branch, its deps and their bases\n    \n    Signed-off-by: Marc Weber <marco-oweber@gmx.de>\n\ndiff --git a/.gitignore b/.gitignore\nindex eb56446..2f6d991 100644\n--- a/.gitignore\n+++ b/.gitignore\n@@ -21,6 +21,8 @@\n /tg-import.txt\n /tg-remote\n /tg-remote.txt\n+/tg-push\n+/tg-push.txt\n /tg\n .*.swp\n \ndiff --git a/README b/README\nindex d2f095d..495c70b 100644\n--- a/README\n+++ b/README\n@@ -480,6 +480,12 @@ tg update\n \n \tTODO: tg update -a for updating all topic branches\n \n+tg push\n+~~~~~~~\n+\tpushes a TopGit-controlled topic branch to a remote\n+\trepository.  By default the remote gets all dependencies\n+\t(both tgish and non-tgish) and bases pushed to.\n+\n TODO: tg rename\n \n \ndiff --git a/tg-push.sh b/tg-push.sh\nnew file mode 100644\nindex 0000000..5df5073\n--- /dev/null\n+++ b/tg-push.sh\n@@ -0,0 +1,78 @@\n+#!/bin/sh\n+# TopGit - A different patch queue manager\n+# GPLv2\n+\n+remotes=\"$base_remote\" # honor -r flag of the tg command\n+\n+## Parse options see README\n+\n+recurse_deps=true\n+tgish_deps_only=false\n+dry_run=\n+\n+while [ -n \"$1\" ]; do\n+\targ=\"$1\"; shift\n+\tcase \"$arg\" in\n+\t--no-deps)\n+\t\trecurse_deps=false;;\n+\t--dry-run)\n+\t\tdry_run=--dry-run;;\n+\t--tgish-only)\n+\t\ttgish_deps_only=true;;\n+\t-h|--help)\n+\t\techo \"Usage: tg [-r remote] push [--dry-run] [--no-deps] [--tgish-only] [-r \"remote2 remote3\"]* branch*\"\n+\t\texit 0;;\n+\t-r)\n+\t\tremotes=\"$remotes $1\"\n+\t\tshift\n+\t\t;;\n+\t*)\n+\t\tbranches=\"$branches $arg\";;\n+\tesac\n+done\n+\n+if [ -z \"$remotes\" ]; then\n+\tremotes=\"$(git config topgit.remote 2>/dev/null)\"\n+fi\n+\n+if [ -z \"$remotes\" ]; then\n+\tdie \"no remote location given. Either use -r remote argument or set topgit.remote\"\n+fi\n+\n+if [ -z \"$branches\" ]; then\n+\tbranches=\"$(git symbolic-ref HEAD | sed 's#^refs/heads/##')\"\n+fi\n+\n+for name in $branches; do\n+\tref_exists \"$name\" || die \"detached HEAD? Can't push $name\"\n+done\n+\n+push_branch(){\n+\t# if so desired omit non tgish deps\n+\t$tgish_deps_only && [ -z \"$_dep_is_tgish\" ] && return 0\n+\n+\techo \"$_dep\"\n+\tlocal base=\"top-bases/$_dep\"\n+\tif ref_exists \"$base\"; then\n+\t\techo \"top-bases/$_dep\"\n+\telse\n+\t\techo \"warning, no base found $base\" 1>&2\n+\tfi\n+}\n+\n+for remote in $remotes; do\n+\tfor name in $branches; do\n+\t\tlist=\"$(\n+\t\t\t# deps\n+\t\t\tif $recurse_deps; then\n+\t\t\t\tno_remotes=1 recurse_deps push_branch \"$name\"\n+\t\t\tfi\n+\t\t\t# current branch\n+\t\t\t_dep=\"$name\"\n+\t\t\t_dep_is_tgish=1\n+\t\t\tpush_branch \"$name\"\n+\t\t)\"\n+\t\techo \"pushing:\"; echo $list\n+        git push $dry_run \"$remote\" $list\n+\tdone\n+done\ndiff --git a/tg.sh b/tg.sh\nindex 0804f73..7d98dbd 100644\n--- a/tg.sh\n+++ b/tg.sh\n@@ -136,6 +136,7 @@ branch_annihilated()\n # of the whole function.\n # If recurse_deps() hits missing dependencies, it will append\n # them to space-separated $missing_deps list and skip them.\n+# set no_remotes to any value to omit remote dependencies (-> tg push)\n recurse_deps()\n {\n \t_cmd=\"$1\"; shift\n@@ -145,9 +146,8 @@ recurse_deps()\n \t_depsfile=\"$(mktemp -t tg-depsfile.XXXXXX)\"\n \t# Check also our base against remote base. Checking our head\n \t# against remote head has to be done in the helper.\n-\tif has_remote \"top-bases/$_name\"; then\n+\thas_remote \"top-bases/$_name\" && [ -z \"$no_remotes\" ] &&\n \t\techo \"refs/remotes/$base_remote/top-bases/$_name\" >>\"$_depsfile\"\n-\tfi\n \n \t# if the branch was annihilated, there exists no .topdeps file\n \tif ! branch_annihilated \"$_name\"; then\n@@ -366,6 +366,8 @@ help|--help|-h)\n --hooks-path)\n \t# Internal command\n \techo \"@hooksdir@\";;\n+eval)\n+\teval \"$@\";;\n *)\n \t[ -r \"@cmddir@\"/tg-$cmd ] || {\n \t\techo \"Unknown subcommand: $cmd\" >&2\n"},{"id":"113593","messageId":"20090511213936.GB17322@piper.oerlikon.madduck.net","threadId":"19060","inReplyTo":"20090511210614.GA6118@gmx.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"martin f krafft","fromEmail":"madduck@madduck.net","sentAt":"2009-05-11T21:39:36Z","receivedAt":"2009-05-11T21:39:36Z","isPatch":true,"sender":{"key":"madduck@madduck.net","avatar":null},"body":"also sprach Marc Weber <marco-oweber@gmx.de> [2009.05.11.2306 +0200]:\n> commit 0bfa198a3cae72d75ca1311bb7a8d495ca2b42cc\n> Author: Marc Weber <marco-oweber@gmx.de>\n> Date:   Mon May 11 23:04:20 2009 +0200\n> \n>     add tg-push pushing the branch, its deps and their bases\n>     \n>     Signed-off-by: Marc Weber <marco-oweber@gmx.de>\n\nSigned-off-by: martin f. krafft <madduck@madduck.net>\n\nThanks, Marc!\n\n-- \nmartin | http://madduck.net/ | http://two.sentenc.es/\n \n* Overfiend came out of the womb complaining.\n                                                    -- #debian-devel\n \nspamtraps: madduck.bogus@madduck.net\n"},{"id":"113610","messageId":"20090512051334.GA22757@pengutronix.de","threadId":"19060","inReplyTo":"20090511210614.GA6118@gmx.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"Uwe Kleine-König","fromEmail":"u.kleine-koenig@pengutronix.de","sentAt":"2009-05-12T05:13:34Z","receivedAt":"2009-05-12T05:13:34Z","isPatch":true,"sender":{"key":"u.kleine-koenig@pengutronix.de","avatar":"https://gravatar.com/avatar/354b5e3ceb2806a2f1e1e382ac29ddbdad18288654da62b61eb13583a857eee7?d=mp&s=160"},"body":"Hello Marc,\n\nOn Mon, May 11, 2009 at 11:06:14PM +0200, Marc Weber wrote:\n> Thanks to Bert Wesarg, Uwe Kleine-König and Martin f Krafft the\n> patch is finally ready to be comitted (?) I included ukleineks last\n> nitpicks.\n> \n> ukleinek, usage line: remote2 = just another remote location.\nhhm, so you suggest that you can add more than one remote per -r option?\nI wouldn't document even if it works now.\n\n> diff --git a/.gitignore b/.gitignore\n> index eb56446..2f6d991 100644\n> --- a/.gitignore\n> +++ b/.gitignore\n> @@ -21,6 +21,8 @@\n>  /tg-import.txt\n>  /tg-remote\n>  /tg-remote.txt\n> +/tg-push\n> +/tg-push.txt\n>  /tg\n>  .*.swp\n>  \n> diff --git a/README b/README\n> index d2f095d..495c70b 100644\n> --- a/README\n> +++ b/README\n> @@ -480,6 +480,12 @@ tg update\n>  \n>  \tTODO: tg update -a for updating all topic branches\n>  \n> +tg push\n> +~~~~~~~\n> +\tpushes a TopGit-controlled topic branch to a remote\n> +\trepository.  By default the remote gets all dependencies\n> +\t(both tgish and non-tgish) and bases pushed to.\n> +\n>  TODO: tg rename\n>  \n>  \n> diff --git a/tg-push.sh b/tg-push.sh\n> new file mode 100644\n> index 0000000..5df5073\n> --- /dev/null\n> +++ b/tg-push.sh\n> @@ -0,0 +1,78 @@\n> +#!/bin/sh\n> +# TopGit - A different patch queue manager\n> +# GPLv2\n> +\n> +remotes=\"$base_remote\" # honor -r flag of the tg command\n> +\n> +## Parse options see README\n> +\n> +recurse_deps=true\n> +tgish_deps_only=false\n> +dry_run=\n> +\n> +while [ -n \"$1\" ]; do\n> +\targ=\"$1\"; shift\n> +\tcase \"$arg\" in\n> +\t--no-deps)\n> +\t\trecurse_deps=false;;\n> +\t--dry-run)\n> +\t\tdry_run=--dry-run;;\n> +\t--tgish-only)\n> +\t\ttgish_deps_only=true;;\n> +\t-h|--help)\n> +\t\techo \"Usage: tg [-r remote] push [--dry-run] [--no-deps] [--tgish-only] [-r \"remote2 remote3\"]* branch*\"\n> +\t\texit 0;;\n> +\t-r)\n> +\t\tremotes=\"$remotes $1\"\n> +\t\tshift\n> +\t\t;;\n> +\t*)\n> +\t\tbranches=\"$branches $arg\";;\n> +\tesac\n> +done\n> +\n> +if [ -z \"$remotes\" ]; then\n> +\tremotes=\"$(git config topgit.remote 2>/dev/null)\"\n> +fi\nThis is obsolete with remotes=$base_remote above, right?\n\n> +if [ -z \"$remotes\" ]; then\n> +\tdie \"no remote location given. Either use -r remote argument or set topgit.remote\"\n> +fi\n> +\n> +if [ -z \"$branches\" ]; then\n> +\tbranches=\"$(git symbolic-ref HEAD | sed 's#^refs/heads/##')\"\n> +fi\n> +\n> +for name in $branches; do\n> +\tref_exists \"$name\" || die \"detached HEAD? Can't push $name\"\n> +done\n> +\n> +push_branch(){\n> +\t# if so desired omit non tgish deps\n> +\t$tgish_deps_only && [ -z \"$_dep_is_tgish\" ] && return 0\n> +\n> +\techo \"$_dep\"\n> +\tlocal base=\"top-bases/$_dep\"\n> +\tif ref_exists \"$base\"; then\n> +\t\techo \"top-bases/$_dep\"\n> +\telse\n> +\t\techo \"warning, no base found $base\" 1>&2\n> +\tfi\n> +}\n> +\n> +for remote in $remotes; do\n> +\tfor name in $branches; do\n> +\t\tlist=\"$(\n> +\t\t\t# deps\n> +\t\t\tif $recurse_deps; then\n> +\t\t\t\tno_remotes=1 recurse_deps push_branch \"$name\"\n> +\t\t\tfi\n> +\t\t\t# current branch\n> +\t\t\t_dep=\"$name\"\n> +\t\t\t_dep_is_tgish=1\n> +\t\t\tpush_branch \"$name\"\n> +\t\t)\"\n> +\t\techo \"pushing:\"; echo $list\n> +        git push $dry_run \"$remote\" $list\n> +\tdone\n> +done\n> diff --git a/tg.sh b/tg.sh\n> index 0804f73..7d98dbd 100644\n> --- a/tg.sh\n> +++ b/tg.sh\n> @@ -136,6 +136,7 @@ branch_annihilated()\n>  # of the whole function.\n>  # If recurse_deps() hits missing dependencies, it will append\n>  # them to space-separated $missing_deps list and skip them.\n> +# set no_remotes to any value to omit remote dependencies (-> tg push)\n>  recurse_deps()\n>  {\n>  \t_cmd=\"$1\"; shift\n> @@ -145,9 +146,8 @@ recurse_deps()\n>  \t_depsfile=\"$(mktemp -t tg-depsfile.XXXXXX)\"\n>  \t# Check also our base against remote base. Checking our head\n>  \t# against remote head has to be done in the helper.\n> -\tif has_remote \"top-bases/$_name\"; then\n> +\thas_remote \"top-bases/$_name\" && [ -z \"$no_remotes\" ] &&\n>  \t\techo \"refs/remotes/$base_remote/top-bases/$_name\" >>\"$_depsfile\"\n> -\tfi\n>  \n>  \t# if the branch was annihilated, there exists no .topdeps file\n>  \tif ! branch_annihilated \"$_name\"; then\n> @@ -366,6 +366,8 @@ help|--help|-h)\n>  --hooks-path)\n>  \t# Internal command\n>  \techo \"@hooksdir@\";;\n> +eval)\n> +\teval \"$@\";;\n>  *)\n>  \t[ -r \"@cmddir@\"/tg-$cmd ] || {\n>  \t\techo \"Unknown subcommand: $cmd\" >&2\nhhhm, this hunk is new and unused.  Intended?\n\nIf it's OK for you I fix these up when commiting.  I will break out the\nchange to tg.sh as shown yesterday in irc.\n\nBest regards\nUwe\n\n-- \nPengutronix e.K.                              | Uwe Kleine-König            |\nIndustrial Linux Solutions                    | http://www.pengutronix.de/  |\n"},{"id":"113612","messageId":"36ca99e90905112322v2aa93a34te9d4a9baf6b6da92@mail.gmail.com","threadId":"19060","inReplyTo":"20090512051334.GA22757@pengutronix.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"Bert Wesarg","fromEmail":"bert.wesarg@googlemail.com","sentAt":"2009-05-12T06:22:13Z","receivedAt":"2009-05-12T06:22:13Z","isPatch":true,"sender":{"key":"bert.wesarg@googlemail.com","avatar":"https://avatars.githubusercontent.com/u/111934?v=4"},"body":"2009/5/12 Uwe Kleine-König <u.kleine-koenig@pengutronix.de>:\n> Hello Marc,\n>\n> On Mon, May 11, 2009 at 11:06:14PM +0200, Marc Weber wrote:\n>> Thanks to Bert Wesarg, Uwe Kleine-König and Martin f Krafft the\n>> patch is finally ready to be comitted (?) I included ukleineks last\n>> nitpicks.\n>>\n>> ukleinek, usage line: remote2 = just another remote location.\n> hhm, so you suggest that you can add more than one remote per -r option?\n> I wouldn't document even if it works now.\nThat was my intention my asking for the -r option. The -r option is to\n'tg' not a tg-command. And it's still not addressed.\n\nBert\n"},{"id":"113618","messageId":"20090512075413.GA7764@gmx.de","threadId":"19060","inReplyTo":"20090512051334.GA22757@pengutronix.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"Marc Weber","fromEmail":"marco-oweber@gmx.de","sentAt":"2009-05-12T07:54:13Z","receivedAt":"2009-05-12T07:54:13Z","isPatch":true,"sender":{"key":"marco-oweber@gmx.de","avatar":null},"body":"> hhhm, this hunk is new and unused.  Intended?\n> \n> If it's OK for you I fix these up when commiting.  I will break out the\n> change to tg.sh as shown yesterday in irc.\n\nthank you x-times :-)\nSure that's fine with me. I already told you.\n\n>That was my intention my asking for the -r option. The -r option is to\n>'tg' not a tg-command. And it's still not addressed.\nBert: You're wrong:\n\ntg.sh contains:\n\n  base_remote=\"$(git config topgit.remote 2>/dev/null)\" || :\n\n  [...]\n\n  if [ \"$1\" = \"-r\" ]; then\n          shift\n          if [ -z \"$1\" ]; then\n                  echo \"Option -r requires an argument.\" >&2\n                  do_help\n                  exit 1\n          fi\n          base_remote=\"$1\"; shift\n          tg=\"$tg -r $base_remote\"\n  fi\n\nSo base_remote is set by config first and then overwritten by the first\n-r flag. my remotes is initialised with that -r flag.\n\nBoy However its wrong again now:\n\nIf you use tg push -r foo it will push to poth: the config value and\nfoo. So probably its best to remove the second -r altogether and replace\nmy remotes by base_remote. You still can use the undocumented -r \"remote\nremote2\" feature.\n\nMarc Weber\n"},{"id":"113622","messageId":"36ca99e90905120155x1954bdf2n2cd015dd0c28af3c@mail.gmail.com","threadId":"19060","inReplyTo":"20090512075413.GA7764@gmx.de","subject":"Re: [PATCH] topgit tg push feature","fromName":"Bert Wesarg","fromEmail":"bert.wesarg@googlemail.com","sentAt":"2009-05-12T08:55:50Z","receivedAt":"2009-05-12T08:55:50Z","isPatch":true,"sender":{"key":"bert.wesarg@googlemail.com","avatar":"https://avatars.githubusercontent.com/u/111934?v=4"},"body":"On Tue, May 12, 2009 at 09:54, Marc Weber <marco-oweber@gmx.de> wrote:\n>>That was my intention my asking for the -r option. The -r option is to\n>>'tg' not a tg-command. And it's still not addressed.\n> Bert: You're wrong:\n>\n> tg.sh contains:\n>\n>  base_remote=\"$(git config topgit.remote 2>/dev/null)\" || :\n>\n>  [...]\n>\n>  if [ \"$1\" = \"-r\" ]; then\n>          shift\n>          if [ -z \"$1\" ]; then\n>                  echo \"Option -r requires an argument.\" >&2\n>                  do_help\n>                  exit 1\n>          fi\n>          base_remote=\"$1\"; shift\n>          tg=\"$tg -r $base_remote\"\n>  fi\n>\n> So base_remote is set by config first and then overwritten by the first\n> -r flag. my remotes is initialised with that -r flag.\nAhh, thanks for the pointer, I haven't seen this line.\n\nUnfortunately I haven't tested it yet. But I'm looking forward to use it.\n\nBert\n\n>\n> Marc Weber\n"},{"id":"113623","messageId":"20090512090201.GA10150@pengutronix.de","threadId":"19060","inReplyTo":"36ca99e90905120155x1954bdf2n2cd015dd0c28af3c@mail.gmail.com","subject":"Re: [PATCH] topgit tg push feature","fromName":"Uwe Kleine-König","fromEmail":"u.kleine-koenig@pengutronix.de","sentAt":"2009-05-12T09:02:01Z","receivedAt":"2009-05-12T09:02:01Z","isPatch":true,"sender":{"key":"u.kleine-koenig@pengutronix.de","avatar":"https://gravatar.com/avatar/354b5e3ceb2806a2f1e1e382ac29ddbdad18288654da62b61eb13583a857eee7?d=mp&s=160"},"body":"Hello,\n\n> Ahh, thanks for the pointer, I haven't seen this line.\nI changed the remote handling a bit and pushed it out.  IMO we could now\nremove the push entries added by tg and then call it 0.8 after some\ntesting.\n\nBest regards\nUwe\n\n-- \nPengutronix e.K.                              | Uwe Kleine-König            |\nIndustrial Linux Solutions                    | http://www.pengutronix.de/  |\n"},{"id":"113760","messageId":"1242209046-9416-1-git-send-email-u.kleine-koenig@pengutronix.de","threadId":"19060","inReplyTo":"20090512090201.GA10150@pengutronix.de","subject":"[PATCH] tg-remote: don't add push specs but warn about existing ones.","fromName":"Uwe Kleine-König","fromEmail":"u.kleine-koenig@pengutronix.de","sentAt":"2009-05-13T10:04:06Z","receivedAt":"2009-05-13T10:04:06Z","isPatch":true,"sender":{"key":"u.kleine-koenig@pengutronix.de","avatar":"https://gravatar.com/avatar/354b5e3ceb2806a2f1e1e382ac29ddbdad18288654da62b61eb13583a857eee7?d=mp&s=160"},"body":"topgit used to add some push specs to assert that topbases are pushed,\ntoo.  This should now be handled by tg-push.\n\nSigned-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>\nCc: Marc Weber <marco-oweber@gmx.de>\nCc: martin f. krafft <madduck@debian.org>\nCc: 528442@bugs.debian.org\n---\n tg-remote.sh |    9 +++++++--\n 1 files changed, 7 insertions(+), 2 deletions(-)\n\ndiff --git a/tg-remote.sh b/tg-remote.sh\nindex 3a40081..86dcd9a 100644\n--- a/tg-remote.sh\n+++ b/tg-remote.sh\n@@ -28,8 +28,13 @@ git config \"remote.$name.url\" >/dev/null || die \"unknown remote '$name'\"\n ## Configure the remote\n \n git config --replace-all \"remote.$name.fetch\" \"+refs/top-bases/*:refs/remotes/$name/top-bases/*\" \"\\\\+refs/top-bases/\\\\*:refs/remotes/$name/top-bases/\\\\*\"\n-git config --replace-all \"remote.$name.push\" \"+refs/top-bases/*:refs/top-bases/*\" \"\\\\+refs/top-bases/\\\\*:refs/top-bases/\\\\*\"\n-git config --replace-all \"remote.$name.push\" \"+refs/heads/*:refs/heads/*\" \"\\\\+refs/heads/\\\\*:refs/heads/\\\\*\"\n+\n+if git config --get-all \"remote.$name.push\" \"\\\\+refs/top-bases/\\\\*:refs/top-bases/\\\\*\" >/dev/null && test \"xtrue\" != \"x$(git config --bool --get topgit.dontwarnonoldpushspecs)\"; then\n+\tinfo \"Probably you want to remove the push specs introduced by an old version of topgit:\"\n+\tinfo '       git config --unset-all \"remote.'$name'.push\" \"\\\\+refs/top-bases/\\\\*:refs/top-bases/\\\\*\"'\n+\tinfo '       git config --unset-all \"remote.'$name'.push\" \"\\\\+refs/heads/\\\\*:refs/heads/\\\\*\"'\n+\tinfo '(or use git config --bool --add topgit.dontwarnonoldpushspecs true to get rid of this warning)'\n+fi\n \n info \"Remote $name can now follow TopGit topic branches.\"\n if [ -z \"$populate\" ]; then\n-- \n1.6.2.4\n"},{"id":"113774","messageId":"20090513114207.GB11669@piper.oerlikon.madduck.net","threadId":"19060","inReplyTo":"1242209046-9416-1-git-send-email-u.kleine-koenig@pengutronix.de","subject":"Re: [PATCH] tg-remote: don't add push specs but warn about existing ones.","fromName":"martin f krafft","fromEmail":"madduck@debian.org","sentAt":"2009-05-13T11:42:07Z","receivedAt":"2009-05-13T11:42:07Z","isPatch":true,"sender":{"key":"madduck@debian.org","avatar":null},"body":"also sprach Uwe Kleine-König <u.kleine-koenig@pengutronix.de> [2009.05.13.1204 +0200]:\n> Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>\n> Cc: Marc Weber <marco-oweber@gmx.de>\n> Cc: martin f. krafft <madduck@debian.org>\n\nSigned-off-by: martin f. krafft <madduck@debian.org>\n\n> diff --git a/tg-remote.sh b/tg-remote.sh\n> index 3a40081..86dcd9a 100644\n> --- a/tg-remote.sh\n> +++ b/tg-remote.sh\n> @@ -28,8 +28,13 @@ git config \"remote.$name.url\" >/dev/null || die \"unknown remote '$name'\"\n>  ## Configure the remote\n>  \n>  git config --replace-all \"remote.$name.fetch\" \"+refs/top-bases/*:refs/remotes/$name/top-bases/*\" \"\\\\+refs/top-bases/\\\\*:refs/remotes/$name/top-bases/\\\\*\"\n> -git config --replace-all \"remote.$name.push\" \"+refs/top-bases/*:refs/top-bases/*\" \"\\\\+refs/top-bases/\\\\*:refs/top-bases/\\\\*\"\n> -git config --replace-all \"remote.$name.push\" \"+refs/heads/*:refs/heads/*\" \"\\\\+refs/heads/\\\\*:refs/heads/\\\\*\"\n> +\n> +if git config --get-all \"remote.$name.push\" \"\\\\+refs/top-bases/\\\\*:refs/top-bases/\\\\*\" >/dev/null && test \"xtrue\" != \"x$(git config --bool --get topgit.dontwarnonoldpushspecs)\"; then\n> +\tinfo \"Probably you want to remove the push specs introduced by an old version of topgit:\"\n> +\tinfo '       git config --unset-all \"remote.'$name'.push\" \"\\\\+refs/top-bases/\\\\*:refs/top-bases/\\\\*\"'\n> +\tinfo '       git config --unset-all \"remote.'$name'.push\" \"\\\\+refs/heads/\\\\*:refs/heads/\\\\*\"'\n> +\tinfo '(or use git config --bool --add topgit.dontwarnonoldpushspecs true to get rid of this warning)'\n> +fi\n>  \n>  info \"Remote $name can now follow TopGit topic branches.\"\n>  if [ -z \"$populate\" ]; then\n\nThanks,\n\n-- \n .''`.   martin f. krafft <madduck@d.o>      Related projects:\n: :'  :  proud Debian developer               http://debiansystem.info\n`. `'`   http://people.debian.org/~madduck    http://vcs-pkg.org\n  `-  Debian - when you have better things to do than fixing systems\n \n\"the mind of the thoroughly well-informed man is a dreadful thing.\n it is like a bric-à-brac shop, all monsters and dust,\n with everything priced above its proper value.\"\n                                                        -- oscar wilde\n"}]}