From mboxrd@z Thu Jan 1 00:00:00 1970 Message-Id: From: Enrique Soriano To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net> In-Reply-To: <138575260906030756u287ecfe6x5085e3d11ed0a367@mail.gmail.com> Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v930.3) Date: Wed, 3 Jun 2009 19:19:16 +0200 References: <138575260906030756u287ecfe6x5085e3d11ed0a367@mail.gmail.com> Subject: Re: [9fans] plan 9 regexp Topicbox-Message-UUID: 03de8c54-ead5-11e9-9d60-3106f5b1d025 > But then, how exactly the '?' operator is useful for grep? I was Suppose we want to filter file names ending in '.jpg' and '.jpeg'. We would use this regexp: ; ls | grep '\.jpe?g$' The 'e' is optional (zero or one 'e'). Q