md.rb
Create and manage multiple markdown documents easily.
Some of the key features are:
- Having a simple syntax and api
- Generate, read, update and delete multiple markdown
- Get json from markdown
Install
“em install mdrb
“
“by require ‘mdrb’
“
usage
Create markdown
“by MD.create(“first”, “# Hello”) #first.md MD.create(“first document”, “# Hello”) #first-document.md
“
Create multiple markdown
“by MD.create_many([first,second], [# first,# second]) #first.md second.md
MD.create_many([first document,second document], [# first,# second]) #first-document.md second.md
“
Get json from markdown
“by MD.create(“first”, “# first”) puts json = MD.to_json(“first”)
“
Update markdown
“by MD.update(path, content) MD.update_on(which_line, path, content) MD.update_many()
“
Delete markdown
“by MD.create_many([first,second], [# first, # second]) MD.delete(“first”) MD.delete_many([first, second])
“
Read markdown
“by MD.read() MD.read_many()
“
Testing
rspec
license
MIT | [email protected]