On Sun, May 19, 2013 at 10:05 AM, Felipe Contreras
<felipe.contre...@gmail.com> wrote:
> On Sun, May 19, 2013 at 9:40 AM, Ramkumar Ramachandra
> <artag...@gmail.com> wrote:

>>> +               '-L', '%u,+%u' % [start, len],
>>> +               '--since', $since, from + '^',
>>> +               '--', source]) do |p|
>>> +      p.each do |line|
>>> +        if line =~ /^(\h{40})/
>>> +          id = $1
>>
>> Use $0 and remove the parens: you're matching the whole line.
>
> No, I'm not matching the whole line, but you are right; there's no
> need for groups.

Actually $&.

-- 
Felipe Contreras
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to