[問題] Everything用regexp找檔名?

作者: vernc (cralvin)   2020-07-11 01:44:13
\d{3}.\w{3,4}$
想把不符合上面檔名的全抓出來,下面這些pass
E:\artnonn\【Electromagnetic Wave(POP)】Unlutin koakumapop\001.jpg
E:\artnonn\【Electromagnetic Wave(POP)】Unlutin koakumapop\002.jpg
E:\artnonn\【Electromagnetic Wave(POP)】Unlutin koakumapop\003.png
E:\artnonn\【Electromagnetic Wave(POP)】Unlutin koakumapop\004.jpg
E:\artnonn\【Electromagnetic Wave(POP)】Unlutin koakumapop\005.jpg
E:\artnonn\【Electromagnetic Wave(POP)】Unlutin koakumapop\006.jpg
只想到
e\:\\artnonn\\.*\\([^\n\\]{4,}|[^\n\\]{0,2})\.\w{3,4}$
但如果像下面就抓不到
E:\artnonn\【Electromagnetic Wave(POP)】Unlutin koakumapop\x01.jpg
E:\artnonn\【Electromagnetic Wave(POP)】Unlutin koakumapop\y1x.jpg
請問這要怎處理?
thx
作者: sicao (adios)   2020-07-11 09:01:00
E\:\\artnonn\\.*\\(?!\d{3}\.\w{3,4}$) ??
作者: hsparrot (飛高高)   2020-07-11 12:30:00
!
作者: sicao (adios)   2020-07-13 22:30:00
(E\:\\artnonn\\.*\\(?!\d{3}\.\w{3,4}$)).{3}\.\w{3,4}$(E\:\\artnonn\\.*\\(?!\d{3}\.\w{3,4}$)).{1,}\.\w{3,4}$3F是檔名必定是三碼 4F是檔名可以是一到N碼

Links booklink

Contact Us: admin [ a t ] ucptt.com