Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Matching numbers



    Hi all :))

    Is there a way of matching numeric ranges taking into account
leading zeroes? I want to match, for example, a day of the month,
from 00 to 31, but with leading zeroes. Cannot use <00-31> because it
will match just a '1', too, and something like <0-3><0-9> will match
39, too.

     The last one is not a big problem, because I don't mind the
exact number, in fact I must just match a 'look-like'. What I mean is
that I can safely match ????-??-??, for example, and the function
will work (I just want to know if the file has a date-code in its
first line, for seeing how much time has passed since a package was
last updated), but I would like to learn a bit more about pattern
matching. I know that with zsh I can make this match more precise.

    Thanks a lot in advance :)

    Raúl Núñez de Arenas Coronado

-- 
Linux Registered User 88736
http://www.pleyades.net & http://raul.pleyades.net/



Messages sorted by: Reverse Date, Date, Thread, Author