Skip to content

Latest commit

 

History

3 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mdedit

A terminal Markdown viewer and editor, built with Textual and Rich.

Open a .md file to a fully rendered view (headings, tables, code blocks, lists, block quotes...) and press a single key to toggle into a syntax-highlighted source editor for the same file — then toggle back to see your changes rendered.

Install

pip install git+https://github.com/matplo/mdedit

Usage

mdedit path/to/file.md   # open (or create) a file
mdedit                   # start with a prompt to open/create a file

Key bindings

Key Action
ctrl+t Toggle between view and edit mode
ctrl+s Save
ctrl+r Reload from disk
ctrl+q Quit (prompts if unsaved changes)

Note: if ctrl+s doesn't seem to do anything in your terminal, it may be intercepted by terminal flow control (XON/XOFF). Run stty -ixon in your shell first, or use the Save option from the command palette (ctrl+p).

Development

pip install -e ".[dev]"
pytest
ruff check .
ruff format --check .

Releasing to PyPI

Releases publish automatically via GitHub Actions using trusted publishing (no API token stored anywhere). To cut a release:

  1. Bump __version__ in src/mdedit/__init__.py, commit it.
  2. Tag and push: git tag vX.Y.Z && git push origin vX.Y.Z
  3. The Publish to PyPI workflow builds the sdist/wheel and uploads them.

Roadmap

v1 is intentionally scoped to a single-file, toggle-based view/edit experience. Not yet included (candidates for a future version):

  • Always-rendered, true WYSIWYG editing (edit directly on rendered text, no separate source view)
  • Split-pane side-by-side edit + preview
  • Browser-style navigation history, bookmarks, remote/URL loading
  • Multiple open files / tabs

License

MIT

About

A terminal Markdown viewer and editor built with Textual

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages