Would it be helpful for share the patch merge result from cfbot

Started by Andy Fanabout 5 years ago7 messages
#1Andy Fan
zhihui.fan1213@gmail.com

Currently when people want to review a patch, they have to download / apply
/
maintain the branch manually. Would it be helpful that the reviewer can
just
git fetch a remote branch where all the things have been done already. I
know
that such cost saving is small, but it is a startup cost, so personally I
think it is
a good place to improve. Since we already maintain such remote git repo at
cbfot,
so can we just expose such URL for each item in commitfest then things
would be done?

At the bottom of cfbot, we have words "Please send feedback to thomas
munro",
so I added Tomas in the cc list.

--
Best Regards
Andy Fan

#2Thomas Munro
thomas.munro@gmail.com
In reply to: Andy Fan (#1)
Re: Would it be helpful for share the patch merge result from cfbot

On Fri, Oct 23, 2020 at 2:32 PM Andy Fan <zhihui.fan1213@gmail.com> wrote:

Currently when people want to review a patch, they have to download / apply /
maintain the branch manually. Would it be helpful that the reviewer can just
git fetch a remote branch where all the things have been done already. I know
that such cost saving is small, but it is a startup cost, so personally I think it is
a good place to improve. Since we already maintain such remote git repo at cbfot,
so can we just expose such URL for each item in commitfest then things would be done?

At the bottom of cfbot, we have words "Please send feedback to thomas munro",
so I added Tomas in the cc list.

Hi Andy,

Try this:

git remote add cfbot https://github.com/postgresql-cfbot/postgresql.git
git fetch cfbot commitfest/30/2785
git checkout commitfest/30/2785

#3Thomas Munro
thomas.munro@gmail.com
In reply to: Thomas Munro (#2)
Re: Would it be helpful for share the patch merge result from cfbot

On Fri, Oct 23, 2020 at 2:51 PM Thomas Munro <thomas.munro@gmail.com> wrote:

On Fri, Oct 23, 2020 at 2:32 PM Andy Fan <zhihui.fan1213@gmail.com> wrote:

Currently when people want to review a patch, they have to download / apply /
maintain the branch manually. Would it be helpful that the reviewer can just
git fetch a remote branch where all the things have been done already. I know
that such cost saving is small, but it is a startup cost, so personally I think it is
a good place to improve. Since we already maintain such remote git repo at cbfot,
so can we just expose such URL for each item in commitfest then things would be done?

At the bottom of cfbot, we have words "Please send feedback to thomas munro",
so I added Tomas in the cc list.

Hi Andy,

Try this:

git remote add cfbot https://github.com/postgresql-cfbot/postgresql.git
git fetch cfbot commitfest/30/2785
git checkout commitfest/30/2785

Also, you might like this way of grabbing and applying all the patches
from an archives link and applying them:

$ cat ~/bin/fetch-all-patches.sh
#!/bin/sh
for P in ` curl -s $1 | grep "\.patch" | sed 's|^ *<a
href="|https://www.postgresql.org|;s|&quot;.*||&#39; ` ; do
echo $P
curl -s -O $P
done
$ ~/bin/fetch-all-patches.sh
'/messages/by-id/20200718201532.GV23581@telsasoft.com&
/messages/by-id/attachment/112541/v21-0001-Document-historic-behavior-of-links-to-directori.patch
/messages/by-id/attachment/112542/v21-0002-pg_stat_file-and-pg_ls_dir_-to-use-lstat.patch
/messages/by-id/attachment/112543/v21-0003-Add-tests-on-pg_ls_dir-before-changing-it.patch
/messages/by-id/attachment/112544/v21-0004-Add-pg_ls_dir_metadata-to-list-a-dir-with-file-m.patch
/messages/by-id/attachment/112545/v21-0005-pg_ls_tmpdir-to-show-directories-and-isdir-argum.patch
/messages/by-id/attachment/112546/v21-0006-pg_ls_-dir-to-show-directories-and-isdir-column.patch
/messages/by-id/attachment/112547/v21-0007-Add-pg_ls_dir_recurse-to-show-dir-recursively.patch
/messages/by-id/attachment/112548/v21-0008-pg_ls_logdir-to-ignore-error-if-initial-top-dir-.patch
/messages/by-id/attachment/112549/v21-0009-pg_ls_-dir-to-return-all-the-metadata-from-pg_st.patch
/messages/by-id/attachment/112550/v21-0010-pg_ls_-to-show-file-type-and-show-special-files.patch
$ git am v21-*.patch

#4Andy Fan
zhihui.fan1213@gmail.com
In reply to: Thomas Munro (#3)
Re: Would it be helpful for share the patch merge result from cfbot

On Fri, Oct 23, 2020 at 9:58 AM Thomas Munro <thomas.munro@gmail.com> wrote:

On Fri, Oct 23, 2020 at 2:51 PM Thomas Munro <thomas.munro@gmail.com>
wrote:

On Fri, Oct 23, 2020 at 2:32 PM Andy Fan <zhihui.fan1213@gmail.com>

wrote:

Currently when people want to review a patch, they have to download /

apply /

maintain the branch manually. Would it be helpful that the reviewer

can just

git fetch a remote branch where all the things have been done already.

I know

that such cost saving is small, but it is a startup cost, so

personally I think it is

a good place to improve. Since we already maintain such remote git

repo at cbfot,

so can we just expose such URL for each item in commitfest then things

would be done?

At the bottom of cfbot, we have words "Please send feedback to thomas

munro",

so I added Tomas in the cc list.

Hi Andy,

Try this:

git remote add cfbot https://github.com/postgresql-cfbot/postgresql.git
git fetch cfbot commitfest/30/2785
git checkout commitfest/30/2785

Also, you might like this way of grabbing and applying all the patches
from an archives link and applying them:

$ cat ~/bin/fetch-all-patches.sh
#!/bin/sh
for P in ` curl -s $1 | grep "\.patch" | sed 's|^ *<a
href="|https://www.postgresql.org|;s|&quot;.*||&#39; ` ; do
echo $P
curl -s -O $P
done
$ ~/bin/fetch-all-patches.sh
'
/messages/by-id/20200718201532.GV23581@telsasoft.com
'

/messages/by-id/attachment/112541/v21-0001-Document-historic-behavior-of-links-to-directori.patch

/messages/by-id/attachment/112542/v21-0002-pg_stat_file-and-pg_ls_dir_-to-use-lstat.patch

/messages/by-id/attachment/112543/v21-0003-Add-tests-on-pg_ls_dir-before-changing-it.patch

/messages/by-id/attachment/112544/v21-0004-Add-pg_ls_dir_metadata-to-list-a-dir-with-file-m.patch

/messages/by-id/attachment/112545/v21-0005-pg_ls_tmpdir-to-show-directories-and-isdir-argum.patch

/messages/by-id/attachment/112546/v21-0006-pg_ls_-dir-to-show-directories-and-isdir-column.patch

/messages/by-id/attachment/112547/v21-0007-Add-pg_ls_dir_recurse-to-show-dir-recursively.patch

/messages/by-id/attachment/112548/v21-0008-pg_ls_logdir-to-ignore-error-if-initial-top-dir-.patch

/messages/by-id/attachment/112549/v21-0009-pg_ls_-dir-to-return-all-the-metadata-from-pg_st.patch

/messages/by-id/attachment/112550/v21-0010-pg_ls_-to-show-file-type-and-show-special-files.patch
$ git am v21-*.patch

This is exactly what I want and more than that. Thank you Thomas!

--
Best Regards
Andy Fan

#5Michael Paquier
michael@paquier.xyz
In reply to: Andy Fan (#1)
Re: Would it be helpful for share the patch merge result from cfbot

On Fri, Oct 23, 2020 at 09:31:57AM +0800, Andy Fan wrote:

Currently when people want to review a patch, they have to download / apply
/ maintain the branch manually. Would it be helpful that the reviewer can
just git fetch a remote branch where all the things have been done already. I
know that such cost saving is small, but it is a startup cost, so personally I
think it is a good place to improve. Since we already maintain such remote git repo at
cbfot, so can we just expose such URL for each item in commitfest then things
would be done?

At the bottom of cfbot, we have words "Please send feedback to thomas
munro", so I added Tomas in the cc list.

It seems to me that this problem is not completely related to the CF
bot, no? Automated testing and fetching from a mirror repository
that's automated to fetch patches from the mailing list and apply them
on some custom branches looks like something entirely independent to
me. Saying that, having something like that may be nice to have,
assuming that we also find a way to track in this repo patches that
are not able to apply correctly, meaning that we could forcibly apply
the patches with the conflicts included in what's committed in the
test branch. In terms of my own experience as CFM, I don't think that
this would be really helpful for the CF manager, but for reviewers or
newcomers, that could help in getting involved into the CF.
--
Michael

#6Michael Paquier
michael@paquier.xyz
In reply to: Michael Paquier (#5)
Re: Would it be helpful for share the patch merge result from cfbot

On Fri, Oct 23, 2020 at 11:05:34AM +0900, Michael Paquier wrote:

It seems to me that this problem is not completely related to the CF
bot, no? Automated testing and fetching from a mirror repository
that's automated to fetch patches from the mailing list and apply them
on some custom branches looks like something entirely independent to
me. Saying that, having something like that may be nice to have,
assuming that we also find a way to track in this repo patches that
are not able to apply correctly, meaning that we could forcibly apply
the patches with the conflicts included in what's committed in the
test branch. In terms of my own experience as CFM, I don't think that
this would be really helpful for the CF manager, but for reviewers or
newcomers, that could help in getting involved into the CF.

Please forget that, I just noticed Thomas' replies.

/me hides
--
Michael

#7Kyotaro Horiguchi
horikyota.ntt@gmail.com
In reply to: Andy Fan (#4)
Re: Would it be helpful for share the patch merge result from cfbot

At Fri, 23 Oct 2020 10:01:14 +0800, Andy Fan <zhihui.fan1213@gmail.com> wrote in

On Fri, Oct 23, 2020 at 9:58 AM Thomas Munro <thomas.munro@gmail.com> wrote:

Try this:

git remote add cfbot https://github.com/postgresql-cfbot/postgresql.git
git fetch cfbot commitfest/30/2785
git checkout commitfest/30/2785

Also, you might like this way of grabbing and applying all the patches
from an archives link and applying them:

$ cat ~/bin/fetch-all-patches.sh
#!/bin/sh
for P in ` curl -s $1 | grep "\.patch" | sed 's|^ *<a
href="|https://www.postgresql.org|;s|&quot;.*||&#39; ` ; do
echo $P
curl -s -O $P
done
$ ~/bin/fetch-all-patches.sh
'
/messages/by-id/20200718201532.GV23581@telsasoft.com
'

...

This is exactly what I want and more than that. Thank you Thomas!

That's awfully useful. Thanks for sharing!

regards.

--
Kyotaro Horiguchi
NTT Open Source Software Center