Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add include / exclude configuration option for contentlayer/source-files #122

Closed
schickling opened this issue Feb 10, 2022 · 4 comments
Closed
Labels
feature New feature or request pkg/source-files
Milestone

Comments

@schickling
Copy link
Collaborator

Sometimes the directory structure provided via contentDirPath can contain files that Contentlayer should ignore while processing the "relevant" document files. In order to allow the user to configure with files Contentlayer should consider vs ignore we could introduce an include and/or exclude option in makeSource of contentlayer/source-files.

@schickling schickling added feature New feature or request pkg/source-files labels Feb 10, 2022
@timlrx
Copy link

timlrx commented Feb 11, 2022

How about just watching the files specified by filePathPattern across all defined local defineDocumentType?

@schickling schickling added this to the 0.2.0 milestone Mar 28, 2022
@schickling
Copy link
Collaborator Author

schickling commented Mar 29, 2022

This will be released as part of 0.2.0 which introduces a new option called contentDirInclude and contentDirExclude.

@schickling
Copy link
Collaborator Author

How about just watching the files specified by filePathPattern across all defined local defineDocumentType?

Interesting idea. This is very related to #123. Need to think more about this.

@schickling
Copy link
Collaborator Author

This was just released as part of the new 0.2.1 version. 🚀

Feel free to comment in case you're running into any problems or open a new issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request pkg/source-files
Projects
None yet
Development

No branches or pull requests

2 participants