Provide filter for files excluded from site
hartmans opened this issue · comments
Sam Hartman commented
I'm an Emacs user, and I'd like to exclude my editor backup files from the generated site.
With the code today, I end up with things like index.md~ ending up copied as assets into the generated site.
Obviously I can git clean before publishing or go set up some sort of CI pipeline, but for some of my sites that's more infrastructure than I need.
So I'd like a setting that allows me to exclude files matching a particular predicate from consideration
Enrico Zini commented
You should now be able to add ignore: ['*~']
to .staticfile
to get rid of those files
Sam Hartman commented
It looks like .staticfile was renamed to .staticsite at some point.
There are comments referring to .staticfile in fstree.py and
features/jinja2.py, but the code (and content.md in the reference
documentation) appears to use .staticsite.
It is my intent to submit a PR fixing the references to .staticfile
although that's a few items down on my stack.