From: Junio C Hamano <gitster@pobox.com>
To: Pranit Bauva <pranit.bauva@gmail.com>
Cc: Siddharth Kannan <kannan.siddharth12@gmail.com>,
Git List <git@vger.kernel.org>
Subject: Re: [PATCH] git-parse-remote.sh: Remove op_prep argument
Date: Fri, 03 Feb 2017 21:09:22 -0800 [thread overview]
Message-ID: <xmqqd1ey8rul.fsf@gitster.mtv.corp.google.com> (raw)
In-Reply-To: <CAFZEwPMGTzVuLMSzm8wiNxvia4AV0T79C1ZTfcuO4=Bydz_zQA@mail.gmail.com> (Pranit Bauva's message of "Sat, 4 Feb 2017 05:34:08 +0530")
Pranit Bauva <pranit.bauva@gmail.com> writes:
> So if you want a better commit message then you could probably use this,
> "parse-remote: remove reference to unused op_prep
>
> This argument was introduced in the commit 15a147e618 to help in
> writing out the error message but then in commit 045fac5845, the
> reference to op_prep got removed. Thus the argument is no longer
> useful and is removed.
> "
Expand the reference to commits like so:
15a147e618 ("rebase: use @{upstream} if no upstream specified",
2011-02-09)
Also pay attention to the subject, in which it is unclear whose
argument "op_prep" is. Other than that, your rewrite is more
readable than the original.
The error_on_missing_default_upstream helper function learned to
take op_prep argument with 15a147e618 ("rebase: use @{upstream}
if no upstream specified", 2011-02-09), but as of 045fac5845
("i18n: git-parse-remote.sh: mark strings for translation",
2016-04-19), the argument no longer is used. Remove it.
>> The contrib/examples/git-pull.sh file also has a variable op_prep which is used
>> in one of the messages shown the user. Should I remove this variable as well?
>
> Not really. We have kept the file git-pull.sh just as an example of
> how git-pull was initially implemented. So previously git-pull was a
> shell script which was then ported to C code. After that conversion,
> the shell script was just put as it is in contrib/examples/ as a use
> case of how git-pull should be implemented.
Yes, with s/should/could/. I agree with you that we should leave it
as-is.
prev parent reply other threads:[~2017-02-04 5:09 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-03 18:28 [PATCH] git-parse-remote.sh: Remove op_prep argument Siddharth Kannan
2017-02-04 0:04 ` Pranit Bauva
2017-02-04 5:09 ` Junio C Hamano [this message]
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=xmqqd1ey8rul.fsf@gitster.mtv.corp.google.com \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=kannan.siddharth12@gmail.com \
--cc=pranit.bauva@gmail.com \
/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).