[PATCH 1/2] teach mklog to get name / email from git config when available

Tom de Vries Tom_deVries@mentor.com
Thu Nov 20 22:34:00 GMT 2014


On 20-11-14 17:43, Segher Boessenkool wrote:
> On Thu, Nov 20, 2014 at 05:22:20PM +0100, Tom de Vries wrote:
>> +my $conf = "$ENV{HOME}/.mklog";
>> +if (-f "$conf") {
>> +    open (CONF, "$conf")
>> +	or die "Could not open file '$conf' for reading: $!\n";
>> +    while (<CONF>) {
>> +	if (m/^\s*NAME\s*=\s*(.*)\s*$/)	{
>
> The final \s* never matches anything since the .* gobbles up everything.
> Use .*? if you really want to get rid of the trailing whitespace.
>

Thanks for spotting that, patch updated.

OK for trunk?

Thanks,
- Tom

>
> Segher
>

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Use-.mklog-name-and-email-settings-or-git-settings.patch
Type: text/x-patch
Size: 2210 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20141120/99eb1c12/attachment.bin>


More information about the Gcc-patches mailing list