From: Jakub Narebski <jnareb@gmail.com>
To: Christian Couder <chriscool@tuxfamily.org>
Cc: Junio C Hamano <gitster@pobox.com>,
git@vger.kernel.org,
Johannes Schindelin <Johannes.Schindelin@gmx.de>,
Stephan Beyer <s-beyer@gmx.net>,
Daniel Barkalow <barkalow@iabervon.org>
Subject: Re: [PATCH 2/2] rebase -i: use some kind of config file to save author information
Date: Sat, 20 Jun 2009 02:27:00 -0700 (PDT) [thread overview]
Message-ID: <m3ab43gsrm.fsf@localhost.localdomain> (raw)
In-Reply-To: <20090620023413.3995.3630.chriscool@tuxfamily.org>
Christian Couder <chriscool@tuxfamily.org> writes:
> Subject: [PATCH 2/2] rebase -i: use some kind of config file to save author information
Errr... "kind of" config file? I'd say use config file format for
saving author information.
>
> This is better than saving in a shell script, because it will make
> it much easier to port "rebase -i" to C. This also removes some sed
> regexps and some "eval"s.
Would it? Well, I guess that at least we will avoid problems with
shell quoting and shell variable expansion rules.
>
> Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
> ---
> git-rebase--interactive.sh | 78 +++++++++++++++++++++++---------------------
> 1 files changed, 41 insertions(+), 37 deletions(-)
>
> diff --git a/git-rebase--interactive.sh b/git-rebase--interactive.sh
> +save_author_ident () {
> + GIT_CONFIG="$SAVE_AUTHOR_INFO" git config rebase.author.name \
> + "$author_ident_name" &&
> + GIT_CONFIG="$SAVE_AUTHOR_INFO" git config rebase.author.mail \
> + "$author_ident_mail" &&
> + GIT_CONFIG="$SAVE_AUTHOR_INFO" git config rebase.author.date \
> + "$author_ident_date"
> +}
> +
> +load_author_ident () {
> + GIT_AUTHOR_NAME=$(GIT_CONFIG="$SAVE_AUTHOR_INFO" \
> + git config rebase.author.name) &&
> + GIT_AUTHOR_EMAIL=$(GIT_CONFIG="$SAVE_AUTHOR_INFO" \
> + git config rebase.author.mail) &&
> + GIT_AUTHOR_DATE=$(GIT_CONFIG="$SAVE_AUTHOR_INFO" \
> + git config rebase.author.date)
> }
Why not use --file=<filename> option of git-config instead?
--
Jakub Narebski
Poland
ShadeHawk on #git
next prev parent reply other threads:[~2009-06-20 9:27 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-20 2:34 [PATCH 2/2] rebase -i: use some kind of config file to save author information Christian Couder
2009-06-20 9:27 ` Jakub Narebski [this message]
2009-06-21 5:15 ` Christian Couder
2009-06-21 21:55 ` Johannes Schindelin
2009-06-21 23:15 ` Junio C Hamano
2009-06-22 4:50 ` Christian Couder
2009-06-22 9:19 ` Johannes Schindelin
2009-06-23 5:30 ` Christian Couder
2009-06-23 9:40 ` Johannes Schindelin
2009-06-24 4:36 ` Christian Couder
2009-06-23 4:57 ` Christian Couder
2009-06-23 5:25 ` Junio C Hamano
2009-06-24 4:29 ` Christian Couder
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m3ab43gsrm.fsf@localhost.localdomain \
--to=jnareb@gmail.com \
--cc=Johannes.Schindelin@gmx.de \
--cc=barkalow@iabervon.org \
--cc=chriscool@tuxfamily.org \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=s-beyer@gmx.net \
/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.
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 NNTP newsgroup(s).