statiqdev / Statiq.Web

Statiq Web is a flexible static site generator written in .NET.
https://statiq.dev/web
Other
1.65k stars 235 forks source link

Exclude Certain Files from Input Folder #871

Closed hawkerm closed 2 years ago

hawkerm commented 4 years ago

I have some template helpers I put in an _include directory. Put wyam copies this over to the output and tries to generate the template as another file as well.

Did I miss an easy way to configure ignoring this directory as input? Thanks!

daveaglick commented 4 years ago

Wow, sorry for the late reply. In answer to your question, unfortunately not - the best option for ignoring files is to place them alongside the input directly and refer to them with a relative path (I.e., "../_include/helpers.cshtml". Razor should be just fine with that since it doesn't actually know about the Wyam virtual file system and just uses the normal folder structure.

FWIW, this is totally changed in Statiq Web - it has (or at least will have shortly) the ability to specify globbing patterns to include/exclude for the various pipelines.

daveaglick commented 2 years ago

I'm slowly working on cleaning up some of the issues that came over from Wyam. Since this one is pretty old I'm going to go ahead and close it. Please don't hesitate to comment or open a new one if it turns out this issue is still relevant in Statiq.