On Wed, Jan 9, 2013 at 4:48 PM, Jesús Gabriel y Galán
<[email protected]> wrote:
> On Wed, Jan 9, 2013 at 4:09 PM, Robert Klemme
> <[email protected]> wrote:

>> ruby -r pathname -e 'Pathname.glob("*[^1].png").each(&:delete)'
>
> Careful, as this skips also filename_11.png, filename_21.png, etc.
> Building on this:
>
> ruby -r pathname -e 'Pathname.glob("*_{[^1],??}.png").each(&:delete)'

+1  I wasn't aware that there could be larger numbers. Thank you for
the correction!

Cheers

robert

-- 
remember.guy do |as, often| as.you_can - without end
http://blog.rubybestpractices.com/

-- You received this message because you are subscribed to the Google Groups 
ruby-talk-google group. To post to this group, send email to 
[email protected]. To unsubscribe from this group, send email 
to [email protected]. For more options, visit this 
group at https://groups.google.com/d/forum/ruby-talk-google?hl=en

Reply via email to