Re: Tips on committing

From: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
To: Stephen Frost <sfrost(at)snowman(dot)net>
Cc: Peter Geoghegan <pg(at)bowt(dot)ie>, Bruce Momjian <bruce(at)momjian(dot)us>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, Pg Committers <pgsql-committers(at)postgresql(dot)org>
Subject: Re: Tips on committing
Date: 2018-07-02 16:21:50
Message-ID: 20180702162150.seciy5gct5vdfzaw@alvherre.pgsql
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

On 2018-Jul-02, Stephen Frost wrote:

> > * Do a dry run before really pushing by using --dry-run.
>
> In addition to this, I'd recommend using 'git show' on the results of
> the --dry-run, so that you see what you're really about to push.

Since commit 653530c8b196 I use this little script I borrowed from Magnus, then
page through all of it before pushing.

git push --dry-run 2>&1 | grep -v '^To' | while read line; do
if [ "$line" == "Everything up-to-date" ]; then
echo $line
else
topush=$(echo $line | awk '{print $1}')
git log --format=oneline $topush | cat
git show --format=fuller --color $topush | cat
fi
done | less -R

--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

In response to

Browse pgsql-committers by date

  From Date Subject
Next Message Alvaro Herrera 2018-07-02 16:23:35 Re: pgsql: Add wait event for fsync of WAL segments
Previous Message Stephen Frost 2018-07-02 16:05:47 Re: Tips on committing

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2018-07-02 16:23:35 Re: pgsql: Add wait event for fsync of WAL segments
Previous Message Alexander Korotkov 2018-07-02 16:06:22 Re: [HACKERS] [PATCH] kNN for SP-GiST