Closed sanjarcode closed 5 months ago
The main thing is you need to create a manifest file. You can see an example of one directly in the tool using help:
merge-markdown -h manifest
For your usecase, it would be something like:
./manifest.yml
---
input:
home/1_motivation.md: ""
home/2_resources.md: {noYAML: true}
home/3_roadmap.md: {noYAML: true}
home/4_resouce_itineraries: {noYAML: true}
home/5_project.md: {noYAML: true}
home/6_setup.md: {noYAML: true}
output:
name: merged/myOutputFile.md
---
Then you can simply run the command:
$ merge-markdown -m manifest.yml
Good luck!
Can we add default command/option that creates this file automatically/at runtime? Since it's a simple mapping of the ls
command.
It could be possible to do that, though the whole point of the manifest is the ability to merge/order markdown files anywhere. So in your case, a generate command makes sense, but if you have markdown files in different locations and different depths all over your project, it makes it more convoluted.
I suppose a generate command could just auto-add all .md files under a directory and after it's generated, you can reorder/delete .md files in the manifest as you see fit.
Added with --create <folder>
command. bafd5bd226ff5a91fe176efd1792596af0f6bd89
Will auto-create an initial manifest file for you.
I have the following folder:
How to generate a single md ? I couldn't figure it out using the README. Maybe add the trivial case first, before discussion variations in README