Last active
February 10, 2022 20:25
-
-
Save wildcard/14d1f6cc529546c3fd8b18a4e60957c1 to your computer and use it in GitHub Desktop.
Generate yml directives from md files using find
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
find . -name '*.md' | sort | xargs -IFILE echo "{ \"file\": \"FILE\", \"title\": \" $( basename 'FILE' ) \" }" | jq -s '.' | yq e -P |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I was using this one to create relative file paths + title for md file