Trying to exclude subfolders in one instance only

Hello friends,

I do hope you had a great start to 2023.

Is there any way where I can exclude the subfolders in the content folder - but with only one limitation - I need to exclude those only on one generated page. For all other pages that are being generated, I do need the entire structure to process.

Basically this is my folder structure -

└── fruits
         └── apple
         └── berries
└── sales

In the sales folder (content/sales) I have empty md files ( and - I create these just because it gets easy to create their layouts in one single.html.

On all other pages, I do need everything to process - and that single.html in the layouts/fruits is working perfectly.

In the layouts folder -
layouts/fruits/single.html - process all files and renders every page perfectly (as expected and desired).

However, in the layouts/sales/single.html - I need to ignore the subfolders (and the md files in them). So, only the,, and need to be processed on this page and I need to exclude the two folders (and hence the files in these folders as well) apple and berries.

This is the reason I cannot ignoreFiles in the config.toml file.

Is there any workaround for achieving this ?

Thank you for reading and taking out time to reply.

Stay Safe and Healthy.

Happy 2023 sir.

I believe it will be the “Not Publishing a Page” section with publishResources set to false.

I will keep you posted.

Thanks :slight_smile: