Conditionally insert content into README.md
Closed this issue · 4 comments
danielbachhuber commented
I'd like to add a Travis build indicator to README.md
without including it in readme.txt
. It would be helpful if I could conditionally insert this content into README.md
One implementation could be to be able to supply a pre_render
callback in the config, and just pass the entire contents of what will be rendered in README.md
through the callback if it exists.
MickeyKay commented
+1 - was just trying to figure out this exact same solution. Would love to see this feature.
gitlost commented
+1
stephenharris commented
Example usage:
grunt.initConfig({
wp_readme_to_markdown: {
your_target: {
files: {
'readme.md': 'readme.txt'
},
options: {
post_convert: function( readme ) {
//modify readme (markdown)
return readme;
}
}
},
},
})
gitlost commented
Thanks!