diff -r 306373ccf8fd -r 27d21e5163b8 src/eric7/Project/Project.py --- a/src/eric7/Project/Project.py Wed Apr 10 17:03:56 2024 +0200 +++ b/src/eric7/Project/Project.py Wed May 15 10:45:50 2024 +0200 @@ -6276,12 +6276,10 @@ dirs = [""] if recursiveSearch else self.subdirs[:] + [""] for directory in dirs: - skip = False - for ignore_pattern in ignore_patterns: - if fnmatch.fnmatch(directory, ignore_pattern): - skip = True - break - if skip: + if any( + fnmatch.fnmatch(directory, ignore_pattern) + for ignore_pattern in ignore_patterns + ): continue curpath = ( @@ -6341,14 +6339,28 @@ if isRemote else os.path.basename(fn) ) - for pattern in sorted(self.__pdata["FILETYPES"], reverse=True): + + # check against ignore patterns first (see issue 553) + if any( + fnmatch.fnmatch(bfn, ignore_pattern) + for ignore_pattern in ignore_patterns + ): + continue + + for pattern in self.__pdata["FILETYPES"]: if fnmatch.fnmatch(bfn, pattern): filetype = self.__pdata["FILETYPES"][pattern] break if ( filetype in self.getFileCategories() - and fn not in self.__pdata[filetype] + and ( + fn not in self.__pdata[filetype] + and ( + filetype == "OTHERS" + and os.path.dirname(fn) not in self.__pdata["OTHERS"] + ) + ) and ( filetype != "TRANSLATIONS" or ( @@ -7356,21 +7368,15 @@ if Preferences.getProject( "AutoExecuteMake" ) and not FileSystemUtilities.isRemoteFileName(self.ppath): - self.__executeMake( - questionOnly=self.__pdata["MAKEPARAMS"]["MakeTestOnly"], - interactive=False, - ) + self.__executeMake(questionOnly=self.__pdata["MAKEPARAMS"]["MakeTestOnly"]) @pyqtSlot() - def __executeMake(self, questionOnly=False, interactive=True): + def __executeMake(self, questionOnly=False): """ Private method to execute a project specific make run. @param questionOnly flag indicating to ask make for changes only @type bool - @param interactive flag indicating an interactive invocation (i.e. - through a menu action) - @type bool """ if FileSystemUtilities.isRemoteFileName(self.ppath): EricMessageBox.critical(