>>282
pregexpでできるよ
http://www.ccs.neu.edu/home/dorai/pregexp/pregexp.html
のマニュアルの
3.3.2 Non-greedy quantifiers
参照。