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

Re: PATCH: 3.1.5: Case-insensitive globbing (2)



On Nov 5, 10:26am, Peter Stephenson wrote:
} Subject: PATCH: 3.1.5: Case-insensitive globbing (2)
}
} "Bart Schaefer" wrote:
} > However, I'm curious how (#i) interacts with parenthesis for grouping.
} > For example:
} > 
} > zsh% echo zsh-3.1.5/((#i)src/zle|doc/zsh)/make*
} > 
} > Where does the case-insensitivity stop in that expression?  It would be
} > logical for it to stop at either the vertical bar or the close paren.
} 
} To the best of my knowedge, zsh has never allowed grouping to cross
} directories, i.e. not even (Src/Zle) is supported.

Well, ok, then ... drop the / from the example:

zsh% echo zsh-3.1.5/((#i)src|doc)/make*

Should the case-insensitivity end at the )/ or not?  (I just got these
patches compiled, and presently it does stop at close of group, which I
think is good.)

} everything between the / and the next ) is ignored. [...]
} Documenting it might be an idea.

Yes.

} % /(bin|var)/false
} zsh: permission denied: /
} 
} It seems zsh treats (and has always treated) left parentheses inside the
} command word differently.

Hm.  I don't think grouping needs to work inside the command word, but
there should not be an implicit word break before the paren:

zagzig<7> echo(config.|stamp-)h
config.h stamp-h

Rather I'd expect to see some sort of parse error, or command-not-found.

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com



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