git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
To: Bert Wesarg <bert.wesarg@googlemail.com>
Cc: Petr Baudis <pasky@suse.cz>,
	git@vger.kernel.org, Peter Simons <simons@cryp.to>,
	Per Cederqvist <ceder@lysator.liu.se>,
	Olaf Dabrunz <odabrunz@gmx.net>,
	Thomas Moschny <thomas.moschny@gmx.de>,
	martin f krafft <madduck@madduck.net>,
	martin f krafft <madduck@debian.org>
Subject: Re: [TopGit PATCH 2/6] tg-remote: use default remote if non is given
Date: Mon, 4 Oct 2010 00:00:52 +0200	[thread overview]
Message-ID: <20101003220052.GD28679@pengutronix.de> (raw)
In-Reply-To: <1286141157-30422-2-git-send-email-bert.wesarg@googlemail.com>

Hello,

On Sun, Oct 03, 2010 at 11:25:53PM +0200, Bert Wesarg wrote:
> This is usefull if the remote has new topics and you need to populate the local
> top-bases.
> 
> Signed-off-by: Bert Wesarg <bert.wesarg@googlemail.com>
> 
> ---
>  README       |    2 +-
>  tg-remote.sh |    5 ++++-
>  2 files changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/README b/README
> index c418ff4..5a54468 100644 README
> --- a/README
> +++ b/README
> @@ -327,7 +327,7 @@ tg remote
>  	and 'git push' to operate on them. (Do NOT use 'git push --all'
>  	for your pushes - plain 'git push' will do the right thing.)
>  
> -	It takes a mandatory remote name argument, and optional
> +	It takes a optional remote name argument, and optional
>  	'--populate' switch - use that for your origin-style remote,
>  	it will seed the local topic branch system based on the
>  	remote topic branches. '--populate' will also make 'tg remote'
> diff --git a/tg-remote.sh b/tg-remote.sh
> index 86dcd9a..61774d7 100644 tg-remote.sh
> --- a/tg-remote.sh
> +++ b/tg-remote.sh
> @@ -15,13 +15,16 @@ while [ -n "$1" ]; do
>  	--populate)
>  		populate=1;;
>  	-*)
> -		echo "Usage: tg [...] remote [--populate] REMOTE" >&2
> +		echo "Usage: tg [...] remote [--populate] [REMOTE]" >&2
>  		exit 1;;
>  	*)
>  		name="$arg";;
>  	esac
>  done
>  
> +[ -n "$name" ] ||
> +	name="$base_remote"
> +
Doesn't this need error checking, i.e. what happens if tg remote was
never called before?  Hmm, seems to be a problem that already exists
now?!  Took your patch anyhow.

>  git config "remote.$name.url" >/dev/null || die "unknown remote '$name'"
>  
>  
> -- 
> tg: (29ab4cf..) bw/tg-remote-use-defualt-remote (depends on: master)
> 

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

  parent reply	other threads:[~2010-10-03 22:01 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-03 19:15 planning a new topgit release Uwe Kleine-König
2010-10-03 21:21 ` Bert Wesarg
2010-10-03 21:25   ` [TopGit PATCH 1/6] Let tg-update take a branch parameter Bert Wesarg
2010-10-03 21:25     ` [TopGit PATCH 2/6] tg-remote: use default remote if non is given Bert Wesarg
2010-10-03 21:25       ` [TopGit PATCH 3/6] tg-files: list files changed by the topic branch Bert Wesarg
2010-10-03 21:25         ` [TopGit PATCH 4/6] tg-prev/tg-next: commands to explore dependencies Bert Wesarg
2010-10-03 21:25           ` [TopGit PATCH 5/6] put die() messages to stderr Bert Wesarg
2010-10-03 21:25             ` [TopGit PATCH 6/6] tg-log: short cut to git log Bert Wesarg
     [not found]               ` <AANLkTi=Kwx5avY7xRdWLS931zK2fi7cj5Q8u3++bqRO+@mail.gmail.com>
2010-10-04  6:45                 ` Bert Wesarg
2010-10-04 19:06                   ` [TopGit PATCH] tg-log: move note from tg base to tg log Bert Wesarg
2010-10-04 21:05                     ` Štěpán Němec
2010-10-04 21:08                       ` Bert Wesarg
2010-10-04  6:45                 ` [TopGit PATCH 6/6] tg-log: short cut to git log Uwe Kleine-König
2010-10-03 21:55           ` [TopGit PATCH 4/6] tg-prev/tg-next: commands to explore dependencies Uwe Kleine-König
2010-10-04  6:48             ` Bert Wesarg
2010-10-03 22:03         ` [TopGit PATCH 3/6] tg-files: list files changed by the topic branch Uwe Kleine-König
2010-10-04  6:43           ` Bert Wesarg
2010-10-04  6:47             ` Uwe Kleine-König
2010-10-04  6:50               ` Bert Wesarg
2010-10-04  6:59                 ` Uwe Kleine-König
2010-10-04 13:16                   ` [TopGit PATCH] " Bert Wesarg
2010-10-04 13:52                     ` Uwe Kleine-König
2010-10-04 16:02                       ` Bert Wesarg
2010-10-04 18:27                         ` [TopGit PATCH v3] " Bert Wesarg
2010-10-04 20:09                           ` [TopGit PATCH] tg-patch: use pretty_tree Bert Wesarg
2010-10-04 23:02                             ` Bert Wesarg
2010-10-05  7:18                               ` Uwe Kleine-König
2010-10-05  8:05                                 ` Bert Wesarg
2010-10-05 19:04                                   ` [TopGit PATCH v2] " Bert Wesarg
2010-10-05 20:01                                     ` Uwe Kleine-König
2010-10-05 20:14                                       ` Bert Wesarg
2010-10-05  7:17                           ` [TopGit PATCH v3] tg-files: list files changed by the topic branch Uwe Kleine-König
2010-10-05 19:03                             ` [TopGit PATCH v4] " Bert Wesarg
2010-10-05 22:02                               ` Štěpán Němec
2010-10-06  6:11                                 ` Bert Wesarg
2010-10-03 22:00       ` Uwe Kleine-König [this message]
2010-10-04  3:13       ` [TopGit PATCH 2/6] tg-remote: use default remote if non is given Ævar Arnfjörð Bjarmason
2010-10-04  6:43         ` Uwe Kleine-König
2010-10-03 22:11   ` planning a new topgit release Uwe Kleine-König

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20101003220052.GD28679@pengutronix.de \
    --to=u.kleine-koenig@pengutronix.de \
    --cc=bert.wesarg@googlemail.com \
    --cc=ceder@lysator.liu.se \
    --cc=git@vger.kernel.org \
    --cc=madduck@debian.org \
    --cc=madduck@madduck.net \
    --cc=odabrunz@gmx.net \
    --cc=pasky@suse.cz \
    --cc=simons@cryp.to \
    --cc=thomas.moschny@gmx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).