这个 gitignore 正则表达式如何工作 "*,cover"
How does this gitignore regex work "*,cover"
github提供的python .gitinore有如下正则表达式,
*,cover
于 line 45。
这个正则表达式到底是什么意思?是吗,"anything, then a comma, then the word cover"?
这不是正则表达式,而是通配符。在 regex(正则表达式)中,*
表示 "repeated as many times as you want",并作为后缀运算符出现。在通配符中,*
表示,如您所猜,"anything".
打错了。现在已通过以下 PR 修复。
github提供的python .gitinore有如下正则表达式,
*,cover
于 line 45。
这个正则表达式到底是什么意思?是吗,"anything, then a comma, then the word cover"?
这不是正则表达式,而是通配符。在 regex(正则表达式)中,*
表示 "repeated as many times as you want",并作为后缀运算符出现。在通配符中,*
表示,如您所猜,"anything".
打错了。现在已通过以下 PR 修复。