Skip to content

ashusevim/Markdown-Processor

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Markdown Processor (marcus)

CLI that converts a Markdown file to HTML and writes the result to stdout.

Currently supported

  • Headings: # ... ######
  • Horizontal rules: --- *** ___
  • Blockquotes: > quote
  • Unordered lists: * / - / + item
  • Ordered lists: 1. item
  • Bold: text or text
  • Strikethrough: text
  • Inline code: code
  • Images: alt
  • Raw HTML passthrough lines (not wrapped)
  • Basic paragraph wrapping (non-empty, non-processed lines)

Install

Local (development):

git clone <repo>
cd markdown-processor
npm install
npm run build

Global (exposes marcus):

npm install -g .

Usage

marcus <file.md>

Example:

marcus README.md > README.html

Programmatic (stdout piping):

marcus test.md | grep "<h2>"

Development

Watch mode (needs tsx if desired—currently not listed as dep):

npm run dev

Build:

npm run build

Run built artifact:

npm start README.md

Exit Codes

  • 0 success
  • 1 file read error

Limitations

The parser is order-dependent, does not fully validate Markdown, and may mis-handle edge cases (mixed lists, nested structures, inline formatting inside list items). Treat output as experimental.

Contributing

Issues & PRs welcome. Keep additions small and tested.

License

MIT (recommended)

About

CLI tool that converts a Markdown file to HTML and writes the result to stdout.

Topics

Resources

Stars

Watchers

Forks

Contributors