Subject: Re: [PATCH] git-filter-branch.sh: Allow running in bare repositories

From: Junio C Hamano <[email-masked]>
Date: Wed, 23 Jul 2008 15:29:12 -0700

Petr Baudis <[email-masked]> writes:

> Commit 46eb449c restricted git-filter-branch to non-bare repositories
> unnecessarily; git-filter-branch can work on bare repositories just
> fine.
>
> Cc: Johannes Schindelin <[email-masked]>
> Signed-off-by: Petr Baudis <[email-masked]>
> ---
>
>   I have my own opinion about the readability-fork ratio in this particular
> case, but there's no use arguing about this. ;-)

Grouping commands is perfectly fine when you think the readers may find it
easlier to follow the logic if you grouped them.  Use { } for that kind of
grouping; I do not have any problem with that.

Use of subshell ( ) is often done by inexperienced people or by careless
people without thinking.  Sometimes you would explicitly want to have a
subshell (e.g. when you want to chdir to do something there but do not
want to affect the main program), and sometimes you don't (e.g. you are
grouping just for precedence, and want assignments and side effects done
inside the group visible by the main program).

Careless uses of ( ) wastes reviewer's time because the code inside has to
be studied to find out if the writer really wanted to have an isolated
separate process that subshell gives, or just being plain careless.