@@ -209,10 +209,13 @@ fn get_subtrees() -> Vec<&'static str> {
209209 ]
210210}
211211
212- /// Return the pathspecs to exclude all subtrees
213- fn get_pathspecs_exclude_subtrees ( ) -> Vec < String > {
212+ /// Return the pathspecs to exclude by default
213+ fn get_pathspecs_default_excludes ( ) -> Vec < String > {
214214 get_subtrees ( )
215215 . iter ( )
216+ . chain ( & [
217+ "doc/release-notes/release-notes-*" , // archived notes
218+ ] )
216219 . map ( |s| format ! ( ":(exclude){}" , s) )
217220 . collect ( )
218221}
@@ -333,7 +336,7 @@ fn lint_py_lint() -> LintResult {
333336 let files = check_output (
334337 git ( )
335338 . args ( [ "ls-files" , "--" , "*.py" ] )
336- . args ( get_pathspecs_exclude_subtrees ( ) ) ,
339+ . args ( get_pathspecs_default_excludes ( ) ) ,
337340 ) ?;
338341
339342 let mut cmd = Command :: new ( bin_name) ;
@@ -459,7 +462,7 @@ expected to follow the naming "/doc/release-notes-<PR number>.md".
459462
460463/// Return the pathspecs for whitespace related excludes
461464fn get_pathspecs_exclude_whitespace ( ) -> Vec < String > {
462- let mut list = get_pathspecs_exclude_subtrees ( ) ;
465+ let mut list = get_pathspecs_default_excludes ( ) ;
463466 list. extend (
464467 [
465468 // Permanent excludes
@@ -468,7 +471,6 @@ fn get_pathspecs_exclude_whitespace() -> Vec<String> {
468471 "contrib/windeploy/win-codesign.cert" ,
469472 "doc/README_windows.txt" ,
470473 // Temporary excludes, or existing violations
471- "doc/release-notes/release-notes-0.*" ,
472474 "contrib/init/bitcoind.openrc" ,
473475 "contrib/macdeploy/macdeployqtplus" ,
474476 "src/crypto/sha256_sse4.cpp" ,
@@ -569,7 +571,7 @@ fn lint_includes_build_config() -> LintResult {
569571 "*.cpp" ,
570572 "*.h" ,
571573 ] )
572- . args ( get_pathspecs_exclude_subtrees ( ) )
574+ . args ( get_pathspecs_default_excludes ( ) )
573575 . args ( [
574576 // These are exceptions which don't use bitcoin-build-config.h, rather CMakeLists.txt adds
575577 // these cppflags manually.
0 commit comments