You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@concerted.apache.org by Atri Sharma <at...@gmail.com> on 2015/10/26 16:22:03 UTC

Merging github PRs

Hi Mentors,

I am trying to merge github PRs into github mirror. The steps I followed
were:

https://mahout.apache.org/developers/github.html

However, this still does not allow me to merge requests per se i.e. it does
not show that the original author's branch was merged. Rather, it squashes
the commits and creates a single commit from committer.

Please advice if there is a way we can merge PRs in a way that retains
original author's name automatically.

-- 
Regards,

Atri
*l'apprenant*

Re: Merging github PRs

Posted by Atri Sharma <at...@gmail.com>.
Thanks!
On 26 Oct 2015 21:22, "Roman Shaposhnik" <ro...@shaposhnik.org> wrote:

> What you do is simple (in fact I've got a personal script that
> automates this workflow):
>    wget
> https://patch-diff.githubusercontent.com/raw/apache/incubator-concerted/pull/2.patch
>    git am 2.patch
>    git commit --amend `git log --format=%B -n 1 HEAD | sed -e '1s#$#
> (closes \#2)#'`
>    git push
>
> This will preserve everything. On top of that it'll auto-close the PR
> on GH (that's what
> munging the commit message in the second line does).
>
> Thanks,
> Roman.
>
> On Mon, Oct 26, 2015 at 10:44 AM, Atri Sharma <at...@gmail.com> wrote:
> > https://github.com/apache/incubator-concerted/pull/2
> >
> > On Mon, Oct 26, 2015 at 9:10 PM, Roman Shaposhnik <ro...@shaposhnik.org>
> > wrote:
> >
> >> Give me an example of the patch you're trying to merge and I think I
> >> can help you with the steps.
> >> At least the steps I use in my workflow.
> >>
> >> Thanks,
> >> Roman.
> >>
> >> On Mon, Oct 26, 2015 at 10:22 AM, Atri Sharma <at...@gmail.com>
> wrote:
> >> > Hi Mentors,
> >> >
> >> > I am trying to merge github PRs into github mirror. The steps I
> followed
> >> > were:
> >> >
> >> > https://mahout.apache.org/developers/github.html
> >> >
> >> > However, this still does not allow me to merge requests per se i.e. it
> >> does
> >> > not show that the original author's branch was merged. Rather, it
> >> squashes
> >> > the commits and creates a single commit from committer.
> >> >
> >> > Please advice if there is a way we can merge PRs in a way that retains
> >> > original author's name automatically.
> >> >
> >> > --
> >> > Regards,
> >> >
> >> > Atri
> >> > *l'apprenant*
> >>
> >
> >
> >
> > --
> > Regards,
> >
> > Atri
> > *l'apprenant*
>

Re: Merging github PRs

Posted by Atri Sharma <at...@gmail.com>.
Thanks Jake!

I am sorry for delay in response.

I will immediately add script to the main repo.

On Mon, Oct 26, 2015 at 9:25 PM, Jake Farrell <jf...@apache.org> wrote:

> For accepting github pull requests would recommend adding a script to the
> repo to help with this, makes it a lot easier for new committers to get up
> to speed with the process if the tooling is included with the repo.
>
> Example of what is in use for Mesos:
> https://github.com/apache/mesos/blob/master/support/apply-review.sh#L90
>
> -Jake
>
>
> On Mon, Oct 26, 2015 at 11:51 AM, Roman Shaposhnik <ro...@shaposhnik.org>
> wrote:
>
> > What you do is simple (in fact I've got a personal script that
> > automates this workflow):
> >    wget
> >
> https://patch-diff.githubusercontent.com/raw/apache/incubator-concerted/pull/2.patch
> >    git am 2.patch
> >    git commit --amend `git log --format=%B -n 1 HEAD | sed -e '1s#$#
> > (closes \#2)#'`
> >    git push
> >
> > This will preserve everything. On top of that it'll auto-close the PR
> > on GH (that's what
> > munging the commit message in the second line does).
> >
> > Thanks,
> > Roman.
> >
> > On Mon, Oct 26, 2015 at 10:44 AM, Atri Sharma <at...@gmail.com>
> wrote:
> > > https://github.com/apache/incubator-concerted/pull/2
> > >
> > > On Mon, Oct 26, 2015 at 9:10 PM, Roman Shaposhnik <
> roman@shaposhnik.org>
> > > wrote:
> > >
> > >> Give me an example of the patch you're trying to merge and I think I
> > >> can help you with the steps.
> > >> At least the steps I use in my workflow.
> > >>
> > >> Thanks,
> > >> Roman.
> > >>
> > >> On Mon, Oct 26, 2015 at 10:22 AM, Atri Sharma <at...@gmail.com>
> > wrote:
> > >> > Hi Mentors,
> > >> >
> > >> > I am trying to merge github PRs into github mirror. The steps I
> > followed
> > >> > were:
> > >> >
> > >> > https://mahout.apache.org/developers/github.html
> > >> >
> > >> > However, this still does not allow me to merge requests per se i.e.
> it
> > >> does
> > >> > not show that the original author's branch was merged. Rather, it
> > >> squashes
> > >> > the commits and creates a single commit from committer.
> > >> >
> > >> > Please advice if there is a way we can merge PRs in a way that
> retains
> > >> > original author's name automatically.
> > >> >
> > >> > --
> > >> > Regards,
> > >> >
> > >> > Atri
> > >> > *l'apprenant*
> > >>
> > >
> > >
> > >
> > > --
> > > Regards,
> > >
> > > Atri
> > > *l'apprenant*
> >
>



-- 
Regards,

Atri
*l'apprenant*

Re: Merging github PRs

Posted by Jake Farrell <jf...@apache.org>.
For accepting github pull requests would recommend adding a script to the
repo to help with this, makes it a lot easier for new committers to get up
to speed with the process if the tooling is included with the repo.

Example of what is in use for Mesos:
https://github.com/apache/mesos/blob/master/support/apply-review.sh#L90

-Jake


On Mon, Oct 26, 2015 at 11:51 AM, Roman Shaposhnik <ro...@shaposhnik.org>
wrote:

> What you do is simple (in fact I've got a personal script that
> automates this workflow):
>    wget
> https://patch-diff.githubusercontent.com/raw/apache/incubator-concerted/pull/2.patch
>    git am 2.patch
>    git commit --amend `git log --format=%B -n 1 HEAD | sed -e '1s#$#
> (closes \#2)#'`
>    git push
>
> This will preserve everything. On top of that it'll auto-close the PR
> on GH (that's what
> munging the commit message in the second line does).
>
> Thanks,
> Roman.
>
> On Mon, Oct 26, 2015 at 10:44 AM, Atri Sharma <at...@gmail.com> wrote:
> > https://github.com/apache/incubator-concerted/pull/2
> >
> > On Mon, Oct 26, 2015 at 9:10 PM, Roman Shaposhnik <ro...@shaposhnik.org>
> > wrote:
> >
> >> Give me an example of the patch you're trying to merge and I think I
> >> can help you with the steps.
> >> At least the steps I use in my workflow.
> >>
> >> Thanks,
> >> Roman.
> >>
> >> On Mon, Oct 26, 2015 at 10:22 AM, Atri Sharma <at...@gmail.com>
> wrote:
> >> > Hi Mentors,
> >> >
> >> > I am trying to merge github PRs into github mirror. The steps I
> followed
> >> > were:
> >> >
> >> > https://mahout.apache.org/developers/github.html
> >> >
> >> > However, this still does not allow me to merge requests per se i.e. it
> >> does
> >> > not show that the original author's branch was merged. Rather, it
> >> squashes
> >> > the commits and creates a single commit from committer.
> >> >
> >> > Please advice if there is a way we can merge PRs in a way that retains
> >> > original author's name automatically.
> >> >
> >> > --
> >> > Regards,
> >> >
> >> > Atri
> >> > *l'apprenant*
> >>
> >
> >
> >
> > --
> > Regards,
> >
> > Atri
> > *l'apprenant*
>

Re: Merging github PRs

Posted by Roman Shaposhnik <ro...@shaposhnik.org>.
What you do is simple (in fact I've got a personal script that
automates this workflow):
   wget https://patch-diff.githubusercontent.com/raw/apache/incubator-concerted/pull/2.patch
   git am 2.patch
   git commit --amend `git log --format=%B -n 1 HEAD | sed -e '1s#$#
(closes \#2)#'`
   git push

This will preserve everything. On top of that it'll auto-close the PR
on GH (that's what
munging the commit message in the second line does).

Thanks,
Roman.

On Mon, Oct 26, 2015 at 10:44 AM, Atri Sharma <at...@gmail.com> wrote:
> https://github.com/apache/incubator-concerted/pull/2
>
> On Mon, Oct 26, 2015 at 9:10 PM, Roman Shaposhnik <ro...@shaposhnik.org>
> wrote:
>
>> Give me an example of the patch you're trying to merge and I think I
>> can help you with the steps.
>> At least the steps I use in my workflow.
>>
>> Thanks,
>> Roman.
>>
>> On Mon, Oct 26, 2015 at 10:22 AM, Atri Sharma <at...@gmail.com> wrote:
>> > Hi Mentors,
>> >
>> > I am trying to merge github PRs into github mirror. The steps I followed
>> > were:
>> >
>> > https://mahout.apache.org/developers/github.html
>> >
>> > However, this still does not allow me to merge requests per se i.e. it
>> does
>> > not show that the original author's branch was merged. Rather, it
>> squashes
>> > the commits and creates a single commit from committer.
>> >
>> > Please advice if there is a way we can merge PRs in a way that retains
>> > original author's name automatically.
>> >
>> > --
>> > Regards,
>> >
>> > Atri
>> > *l'apprenant*
>>
>
>
>
> --
> Regards,
>
> Atri
> *l'apprenant*

Re: Merging github PRs

Posted by Atri Sharma <at...@gmail.com>.
https://github.com/apache/incubator-concerted/pull/2

On Mon, Oct 26, 2015 at 9:10 PM, Roman Shaposhnik <ro...@shaposhnik.org>
wrote:

> Give me an example of the patch you're trying to merge and I think I
> can help you with the steps.
> At least the steps I use in my workflow.
>
> Thanks,
> Roman.
>
> On Mon, Oct 26, 2015 at 10:22 AM, Atri Sharma <at...@gmail.com> wrote:
> > Hi Mentors,
> >
> > I am trying to merge github PRs into github mirror. The steps I followed
> > were:
> >
> > https://mahout.apache.org/developers/github.html
> >
> > However, this still does not allow me to merge requests per se i.e. it
> does
> > not show that the original author's branch was merged. Rather, it
> squashes
> > the commits and creates a single commit from committer.
> >
> > Please advice if there is a way we can merge PRs in a way that retains
> > original author's name automatically.
> >
> > --
> > Regards,
> >
> > Atri
> > *l'apprenant*
>



-- 
Regards,

Atri
*l'apprenant*

Re: Merging github PRs

Posted by Roman Shaposhnik <ro...@shaposhnik.org>.
Give me an example of the patch you're trying to merge and I think I
can help you with the steps.
At least the steps I use in my workflow.

Thanks,
Roman.

On Mon, Oct 26, 2015 at 10:22 AM, Atri Sharma <at...@gmail.com> wrote:
> Hi Mentors,
>
> I am trying to merge github PRs into github mirror. The steps I followed
> were:
>
> https://mahout.apache.org/developers/github.html
>
> However, this still does not allow me to merge requests per se i.e. it does
> not show that the original author's branch was merged. Rather, it squashes
> the commits and creates a single commit from committer.
>
> Please advice if there is a way we can merge PRs in a way that retains
> original author's name automatically.
>
> --
> Regards,
>
> Atri
> *l'apprenant*