Re: [RFC/PATCH] git-completion.bash: remove bashism to fix ZSH compatibility

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Il 11/03/2013 19:09, Junio C Hamano ha scritto:
> Matthieu Moy <Matthieu.Moy@xxxxxxxxxxxxxxx> writes:
> 
>> Junio C Hamano <gitster@xxxxxxxxx> writes:
>>
>>> Ahh, thanks for reminding me of this.  You are right; these two
>>> functions are broken when the user has CDPATH set, I think.
>>>
>>> Here is a reroll.
>>
>> Thanks. Even nicer that the previous since the CDPATH implied the
>> subshell anyway.
> 
> Actually, "cd", not CDPATH, is what implies that the caller must be
> calling us in a subshell, e.g.
> 
> 	result=$(__git_ls_files_helper dir/ args...)
> 
> Otherwise the user's shell would have been taken to an unexpected
> place, with or without CDPATH.
> 

Right; this is the reason I used the `{` grouping, instead of `(`.

However, since the `{` is already specified when the function is
defined, I did not add another `{}` grouping.

> [...]


Regards  Manlio Perillo
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAlE+K/4ACgkQscQJ24LbaUQqvwCgmReHb4VtMJDT+tv+XF9RPmXE
DlEAnjhsgXszSBVG1iW0WCLM6212+fdA
=SYzh
-----END PGP SIGNATURE-----
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]