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

How do I (*|*/*) ?



AI told me that (a|b) could be done but when I tried print -l (*|*/*) I got bad pattern.  I thought the AI engine was wrong.  But I read the man pages and it has a|b and (…) so I played and I found that print -l (a|b)* works.  And print -l (*|b).DS_Store works.  It appears as if a or b can not contain a slash? e.g. print -l (*|Movies/TV)/.DS_Store is a bad pattern.

I assume it is because "In filename generation, the character `/' must be matched explicitly;” but I actually don’t see the connection.

I don’t want {a,b} because I’m trying to get a single list that can be sorted.  My original quest is something like: print -l (*|*/*|*/*/*)/.DS_Store(OL[1,5])

Is that possible?






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