pg.ddx.io pgsql-general@postgresql.org mailing list archive
help / color / mirror / Atom feedhttps://wiki.postgresql.org/wiki/Working_with_Git link one link cannot open, another link is unrelated.
3+ messages / 3 participants
[nested] [flat]
* https://wiki.postgresql.org/wiki/Working_with_Git link one link cannot open, another link is unrelated.
@ 2022-12-28 10:01 jian he <jian.universality@gmail.com>
2022-12-29 09:51 ` Re: https://wiki.postgresql.org/wiki/Working_with_Git link one link cannot open, another link is unrelated. Melih Mutlu <m.melihmutlu@gmail.com>
0 siblings, 1 reply; 3+ messages in thread
From: jian he @ 2022-12-28 10:01 UTC (permalink / raw)
To: pgsql-general list <pgsql-general@lists.postgresql.org>
Hi. It's more like a git question less like a postgres question..
I executed the following commands
rm /home/jian/Downloads/001_psql_parse_only_test.patch
git checkout master
git branch --delete --force feature_to_review
git checkout -b feature_to_review
patch -p1 --batch < /home/jian/Downloads/001_psql_parse_only.v1.patch
git commit -a -m "test"
git diff --patience master feature_to_review >
/home/jian/Downloads/001_psql_parse_only_test.patch
git diff --color-words --no-index
/home/jian/Downloads/001_psql_parse_only.v1.patch
/home/jian/Downloads/001_psql_parse_only_test.patch
the last command should return nothing? The idea is to create a local
branch, patch the downloaded patch file, and commit the patch file.
Then try to use git diff to validate local branch = master + patch file by
comparing the download patch file with the output of (git diff branchA
branchB).
Generally what's the correct commands (workflow to patch the patch file)
and how can i validate the local branch only has the patched file changes
and no others.
also in this link: https://wiki.postgresql.org/wiki/Working_with_Git
> See the documentation and tutorials at http://git.or.cz/ for a more
> detailed Git introduction. For a more detailed lesson, check out
> http://progit.org and maybe get a hardcopy to help support the site.
>
the first link not working, the second link, is not that related to git.
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: https://wiki.postgresql.org/wiki/Working_with_Git link one link cannot open, another link is unrelated.
2022-12-28 10:01 https://wiki.postgresql.org/wiki/Working_with_Git link one link cannot open, another link is unrelated. jian he <jian.universality@gmail.com>
@ 2022-12-29 09:51 ` Melih Mutlu <m.melihmutlu@gmail.com>
2023-01-17 18:05 ` Re: https://wiki.postgresql.org/wiki/Working_with_Git link one link cannot open, another link is unrelated. Alvaro Herrera <alvherre@alvh.no-ip.org>
0 siblings, 1 reply; 3+ messages in thread
From: Melih Mutlu @ 2022-12-29 09:51 UTC (permalink / raw)
To: jian he <jian.universality@gmail.com>; +Cc: pgsql-general list <pgsql-general@lists.postgresql.org>
Hi,
jian he <jian.universality@gmail.com>, 28 Ara 2022 Çar, 13:01 tarihinde
şunu yazdı:
> the last command should return nothing?
>
No, a patch file is not the same with diff output. Patches in the mailing
list mostly include some meta information like commit message, commit date,
author name etc. in addition to diff.
That's why git diff will probably find differences between a patch
downloaded from the mailing list and your patch created by git diff.
If differences are only in meta info, stats, indexes etc.and not code
itself, then it should be good.
You may use "git format-patch" to create a patch with similar format to the
ones from the mailing list. But it wouldn't be exactly the same since
dates, commit messages etc will be different.
> The idea is to create a local branch, patch the downloaded patch file, and
> commit the patch file.
> Then try to use git diff to validate local branch = master + patch file by
> comparing the download patch file with the output of (git diff branchA
> branchB).
> Generally what's the correct commands (workflow to patch the patch file)
> and how can i validate the local branch only has the patched file changes
> and no others.
>
Alternatively, you can use "git am <patch_name>" to add the patch as a new
commit to your current branch. Then you'll have master + patch.
also in this link: https://wiki.postgresql.org/wiki/Working_with_Git
>
>> See the documentation and tutorials at http://git.or.cz/ for a more
>> detailed Git introduction. For a more detailed lesson, check out
>> http://progit.org and maybe get a hardcopy to help support the site.
>>
> the first link not working, the second link, is not that related to git.
>
This is just bad. Needs to be updated properly.
Best,
--
Melih Mutlu
Microsoft
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: https://wiki.postgresql.org/wiki/Working_with_Git link one link cannot open, another link is unrelated.
2022-12-28 10:01 https://wiki.postgresql.org/wiki/Working_with_Git link one link cannot open, another link is unrelated. jian he <jian.universality@gmail.com>
2022-12-29 09:51 ` Re: https://wiki.postgresql.org/wiki/Working_with_Git link one link cannot open, another link is unrelated. Melih Mutlu <m.melihmutlu@gmail.com>
@ 2023-01-17 18:05 ` Alvaro Herrera <alvherre@alvh.no-ip.org>
0 siblings, 0 replies; 3+ messages in thread
From: Alvaro Herrera @ 2023-01-17 18:05 UTC (permalink / raw)
To: Melih Mutlu <m.melihmutlu@gmail.com>; +Cc: jian he <jian.universality@gmail.com>; pgsql-general list <pgsql-general@lists.postgresql.org>
On 2022-Dec-29, Melih Mutlu wrote:
> also in this link: https://wiki.postgresql.org/wiki/Working_with_Git
> >
> >> See the documentation and tutorials at http://git.or.cz/ for a more
> >> detailed Git introduction. For a more detailed lesson, check out
> >> http://progit.org and maybe get a hardcopy to help support the site.
> >>
> > the first link not working, the second link, is not that related to git.
>
> This is just bad. Needs to be updated properly.
I have fixed the outdated links now. There are several other things in
those instructions that seem dated -- perhaps not factually wrong, but
they look odd in 2023.
(Hmm, one thing that does seem wrong is that we no longer offer
individual repos under git.postgresql.org; AFAIR we tell people to rely
on external providers such as github/gitlab for that.)
--
Álvaro Herrera PostgreSQL Developer — https://www.EnterpriseDB.com/
Thou shalt study thy libraries and strive not to reinvent them without
cause, that thy code may be short and readable and thy days pleasant
and productive. (7th Commandment for C Programmers)
^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2023-01-17 18:05 UTC | newest]
Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2022-12-28 10:01 https://wiki.postgresql.org/wiki/Working_with_Git link one link cannot open, another link is unrelated. jian he <jian.universality@gmail.com>
2022-12-29 09:51 ` Melih Mutlu <m.melihmutlu@gmail.com>
2023-01-17 18:05 ` Alvaro Herrera <alvherre@alvh.no-ip.org>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox