This PR updates the indexing to be more flexible in some ways and more restrictive in one significant way.
More flexible:
Added a -v (verbose) flag to control runtime logging
Added a -l (languages) parameter to allow for changing what format (yaml, toml, etc) the front-matter is in
Added a -d (delimiter) parameter to allow for changing what sets off the front-matter
Added a -s (stripIndex) flag to handle folders with an index.md file. Without this flag the URI used in the index would be /index, which doesn't work.
Less flexible:
The current system uses grey-matter to handle markdown files and assumes all other files are HTML. On my site this caused the index to include Javascript and image files. This PR changes the file walker to only process .md and .html files. Optionally (based on the verbose flag above), skipped files are noted on the console.
This PR updates the indexing to be more flexible in some ways and more restrictive in one significant way.
More flexible:
-v
(verbose) flag to control runtime logging-l
(languages) parameter to allow for changing what format (yaml, toml, etc) the front-matter is in-d
(delimiter) parameter to allow for changing what sets off the front-matter-s
(stripIndex) flag to handle folders with an index.md file. Without this flag the URI used in the index would beLess flexible: The current system uses
grey-matter
to handle markdown files and assumes all other files are HTML. On my site this caused the index to include Javascript and image files. This PR changes the file walker to only process.md
and.html
files. Optionally (based on the verbose flag above), skipped files are noted on the console.