Prevent temporary editor files from being picked up for POTFILES.in generation

Aparently cmake's file glob also picks up hidden files and doesn't have
an easy way to avoid that.
This commit is contained in:
Geert Janssens 2018-11-04 13:07:36 +01:00
parent 2283df719a
commit 67174dd0b1

View File

@ -88,7 +88,11 @@ function(make_gnucash_potfiles)
foreach (path ${FILES_IN})
if (${path} MATCHES "^(bindings/|borrowed/|common/|doc/|libgnucash/|gnucash/)"
AND
NOT ${path} MATCHES "gw-|test|experimental|python-bindings|swig-.*\\.c")
NOT ${path} MATCHES "gw-|test|experimental|python-bindings|swig-.*\\.c"
# Skip POSIX style hidden files even if they have the proper extension
# These are typically temporary files from editors like emacs
AND
NOT ${path} MATCHES "/[.][^/]*$")
list (APPEND GOOD_FILES ${path})
endif ()
endforeach (path)