{"id":13820995,"url":"https://github.com/smasher164/mexdown","last_synced_at":"2025-05-02T01:31:05.191Z","repository":{"id":57480225,"uuid":"130643946","full_name":"smasher164/mexdown","owner":"smasher164","description":"A lightweight integrating markup language","archived":false,"fork":false,"pushed_at":"2020-02-24T20:07:20.000Z","size":65,"stargazers_count":16,"open_issues_count":1,"forks_count":1,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-04-26T15:50:09.858Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/smasher164.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-04-23T05:21:53.000Z","updated_at":"2024-09-29T05:06:32.000Z","dependencies_parsed_at":"2022-09-26T17:41:38.638Z","dependency_job_id":null,"html_url":"https://github.com/smasher164/mexdown","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/smasher164%2Fmexdown","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/smasher164%2Fmexdown/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/smasher164%2Fmexdown/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/smasher164%2Fmexdown/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/smasher164","download_url":"https://codeload.github.com/smasher164/mexdown/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251969353,"owners_count":21673190,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-04T08:01:13.308Z","updated_at":"2025-05-02T01:31:02.204Z","avatar_url":"https://github.com/smasher164.png","language":"Go","funding_links":[],"categories":["Go"],"sub_categories":[],"readme":"# mexdown\n\n[![Documentation](https://img.shields.io/badge/%E2%80%8B-reference-007d9c?logo=go\u0026logoColor=white)](https://pkg.go.dev/akhil.cc/mexdown)\n[![Build Status](https://travis-ci.org/smasher164/mexdown.svg?branch=master)](https://travis-ci.org/smasher164/mexdown)\n[Blog post](https://www.blog.akhil.cc/mexdown)\n\nmexdown is a lightweight integrating markup language. It offers a syntax similar to markdown's, but its distinguishing feature is in integrating commands to generate a document.\n\nThese commands are processed through **directives**. Simply append a command to a block of raw text, like so:\n\n````\n```dot -Tsvg\ndigraph g{\n  rankdir=LR;\n  \"A\" -\u003e \"B\" -\u003e \"C\"\n  \"B\" -\u003e \"D\"\n}\n```\n````\n\n[**`dot`**](https://www.graphviz.org/doc/info/command.html) is a command installed with Graphviz that reads a graph's description into standard input, and writes its SVG representation to standard output. This SVG can be embedded into an HTML document, so the following mexdown source file\n\n````\n# Title About Graphs\n\nThe following graph illustrates my point:\n```dot -Tsvg\ndigraph g{\n  rankdir=LR;\n  \"A\" -\u003e \"B\" -\u003e \"C\"\n  \"B\" -\u003e \"D\"\n}\n```\n````\n\nwhen run through mexdown's html backend either via the command line,\n\n```\n$ mexdown html graphs.xd\n```\n\nor programmatically with Go,\n\n```\nfile := parser.MustParse(src)\nout, err := html.Gen(file).Output()\n```\n\nproduces the following HTML document\n\n![A graph embedded in an HTML document](doc/mexdown_graph_example.png \"Graph Example\")\n\nDirectives enable a powerful way to control document generation, without building in new language features into markdown itself. As long as the command reads from STDIN and writes to STDOUT, you can\n- Embed mathematical equations.\n- Write literate programs.\n- Generate hyperlinked source-code documentation.\n- Create a table of contents.\n- Embed interactive widgets based off descriptions.\n- Use it in other creative ways!\n\nThe language itself is backend-independent, and the grammar was written with this in mind. For example, the grammar doesn't dictate the formatting of list items, the escaping of raw text, or the command language used for the directives.\n\n## Supported Backends\n\nCurrently, the only implemented backend is HTML. However, the next candidates are\n- PDF\n- Postscript\n- Latex\n- Google Docs/Slides\n- Pandoc\n\nAnyone can implement their own backend, since it only needs the AST, as defined in [akhil.cc/mexdown/ast](https://akhil.cc/mexdown/ast).\n\n## Contributing\nPlease file issues on Github's issue tracker. There is still a lot of work that needs to be done before creating a release. Thank you for taking the time to contribute!","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsmasher164%2Fmexdown","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsmasher164%2Fmexdown","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsmasher164%2Fmexdown/lists"}