how to use regex to express 5~17

B

billy_kn

Guest
I have some files which name billy.1.txt, billy.2.txt ..... billy.17.txt
Now I want to use regex to list billy.6.txt ~ billy.15.txt. What command I could use?
I try to use ll -tr billy.[6-15].txt, it is not work.
and also try below command, all have unexpect result, any idea?
ll -tr billy.[6-9]|1[0-5].txt
ll -tr billy.([6-9]|1[0-5]).txt
ll -tr billy.\([6-9]|1[0-5]\).txt
ll -tr billy."[6-9]|1[0-5]".txt
 


finally, it is work for ll -tr billy.{[6-9],1[0-5]}.txt
 

Staff online


Latest posts

Top