(?m)(?s).*(string1).*(string2).* ->首先搜索string1,然后搜索string2.如果要先搜索string2,则使用(?m)(?s).*(string2).*(string1).* .要了解(?m)和(?s),请转到此处 I want to run file search over files like the guy shown here.I want to find the files containing string1 and string2 . Not string1 or string2.And most importantly the strings can be on different lines.I searched SO for it but I only found it with or clause and the regex is for the same line. Can you help me?What I am looking for is some like this.However I am using windows and my options are limited. Can I achieve this on eclipse? 解决方案 Press +. Go to File Search tab select/check the "Regullar Expression" button and in the Containing text text box, use the blow regular expression(?m)(?s).*(string1).*(string2).* --> Searches string1 first then string2.If you want string2 to be searched first then use (?m)(?s).*(string2).*(string1).*.To know about (?m) and (?s) go here 这篇关于Eclipse文件搜索模式中恰好出现了两次的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 1403页,肝出来的.. 09-08 03:37