1. Regular expressions
Note that wildcard patterns are not regular expressions, although they are a bit similar. First of all, they match filenames, rather than text, and secondly, the conventions are not the same: for example, in a regular expression '*' means zero or more copies of the preceding thing.
Now that regular expressions have bracket expressions where the negation is indicated by a '^', POSIX has declared the effect of a wildcard pattern "[^...]" to be undefined.
译:glob中的通配符模式是用来处理文件名的,而regex是用来处理文本的,其次它们对元字符的解释是不一样的,例如:"*"在正则表达式中是表示匹配0次或者0次以上的意思,而glob中的意思是任意字符。
正则表达式中中括号表达式取反使用"^",但是在glob中这种形式并没有被定义。