{"id":15115797,"url":"https://github.com/iamgio/quarkdown","last_synced_at":"2025-05-16T01:05:28.553Z","repository":{"id":220020328,"uuid":"750550657","full_name":"iamgio/quarkdown","owner":"iamgio","description":"🪐 Markdown with superpowers — from ideas to presentations, articles and books.","archived":false,"fork":false,"pushed_at":"2025-05-13T17:21:25.000Z","size":161756,"stargazers_count":535,"open_issues_count":0,"forks_count":12,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-05-13T18:25:53.671Z","etag":null,"topics":["markdown","markdown-parser","markup-language","paper","pdf","presentations","programming-language","scripting-language","slides","typesetting","typesetting-system"],"latest_commit_sha":null,"homepage":"","language":"Kotlin","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/iamgio.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-01-30T21:13:04.000Z","updated_at":"2025-05-13T17:12:18.000Z","dependencies_parsed_at":"2024-11-10T13:19:45.358Z","dependency_job_id":"46eb78b2-2863-4137-a7b3-e1c20d3875ad","html_url":"https://github.com/iamgio/quarkdown","commit_stats":null,"previous_names":["iamgio/quarkdown"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iamgio%2Fquarkdown","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iamgio%2Fquarkdown/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iamgio%2Fquarkdown/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iamgio%2Fquarkdown/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/iamgio","download_url":"https://codeload.github.com/iamgio/quarkdown/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254448579,"owners_count":22072764,"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":["markdown","markdown-parser","markup-language","paper","pdf","presentations","programming-language","scripting-language","slides","typesetting","typesetting-system"],"created_at":"2024-09-26T01:44:01.320Z","updated_at":"2025-05-16T01:05:23.539Z","avatar_url":"https://github.com/iamgio.png","language":"Kotlin","readme":"\u003cp align=\"center\"\u003e\n  \u003cpicture\u003e\n    \u003csource media=\"(prefers-color-scheme: dark)\" srcset=\"https://raw.githubusercontent.com/iamgio/quarkdown/project-files/images/tbanner-light.svg\"\u003e\n    \u003csource media=\"(prefers-color-scheme: light)\" srcset=\"https://raw.githubusercontent.com/iamgio/quarkdown/project-files/images/tbanner-dark.svg\"\u003e\n    \u003cimg alt=\"Quarkdown banner\" src=\"https://github.com/user-attachments/assets/68dfb3bf-9466-44f3-b220-7067322c4887\"\u003e\n  \u003c/picture\u003e\n  \u003cbr\u003e\n  \u003ca href=\"https://github.com/iamgio/quarkdown/wiki\"\u003e\u003cimg alt=\"Wiki\" src=\"https://img.shields.io/badge/wiki-read-darkcyan\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://pinterest.github.io/ktlint\"\u003e\u003cimg alt=\"FMT: Ktlint\" src=\"https://img.shields.io/badge/fmt-ktlint-7f52ff?logo=kotlin\u0026logoColor=f5f5f5\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://www.codefactor.io/repository/github/iamgio/quarkdown\"\u003e\u003cimg alt=\"CodeFactor\" src=\"https://www.codefactor.io/repository/github/iamgio/quarkdown/badge/main\"\u003e\u003c/a\u003e\n  \u003cbr\u003e\n  \u003cbr\u003e\n  \u003cstrong\u003eDownload\u003c/strong\u003e the latest build \u003cstrong\u003e\u003ca href=\"https://github.com/iamgio/quarkdown/releases\"\u003ehere\u003c/a\u003e\u003c/strong\u003e\u0026nbsp;\n  \u003cbr\u003e\n  \u003chr\u003e\n\u003c/p\u003e\n\n\u0026nbsp;\n\nQuarkdown is a modern Markdown-based typetting system, designed around the key concept of **versatility**, by seamlessly compiling a project\ninto a print-ready book or an interactive presentation.\nAll through an incredibly powerful Turing-complete extension of Markdown, ensuring your ideas flow automatically into paper.\n\n\u0026nbsp;\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://raw.githubusercontent.com/iamgio/quarkdown/project-files/images/paged-demo.png\" alt=\"Paper demo\"\u003e\n  \u003cp align=\"center\"\u003e\u003cem\u003eOriginal credits: \u003ca href=\"https://arxiv.org/abs/1706.03762v7\"\u003eAttention Is All You Need\u003c/a\u003e\u003c/em\u003e\u003c/p\u003e\n\u003c/p\u003e\n\n\u003cbr\u003e\n\nBorn as an extension of CommonMark and GFM, the Quarkdown Flavor brings **functions** to Markdown, along with many other syntax extensions.\n\n\u003cbr\u003e\n\n\u003e This is a function call:\n\u003e ```\n\u003e .somefunction {arg1} {arg2}\n\u003e     Body argument\n\u003e ```\n\n\u003cbr\u003e\n\n**Possibilities are unlimited** thanks to an ever-expanding [standard library](stdlib/src/main/kotlin/eu/iamgio/quarkdown/stdlib),\nwhich offers layout builders, I/O, math, conditional statements and loops.\n\n**Not enough?** You can still define your own functions and variables — all within Markdown.\nYou can even create awesome libraries for everyone to use.\n\n\u003cbr\u003e\n\n\u003e ```\n\u003e .function {greet}\n\u003e     to from:\n\u003e     **Hello, .to** from .from!\n\u003e\n\u003e .greet {world} from:{iamgio}\n\u003e ```\n\u003e Result: **Hello, world** from iamgio!\n\n\u003cbr\u003e\n\nThis out-of-the-box scripting support opens doors to complex and dynamic content that would be otherwise impossible\nto achieve with vanilla Markdown.\n\nCombined with live preview and :zap: fast compilation speed, Quarkdown simply gets the work done.\n\n\u0026nbsp;\n\n\u003cp align=\"center\"\u003e\n\u003cimg src=\"https://raw.githubusercontent.com/iamgio/quarkdown/project-files/video/livepreview.gif\" alt=\"Live preview\" /\u003e\n\u003c/p\u003e\n\n\u0026nbsp;\n\nCheck the [wiki](https://github.com/iamgio/quarkdown/wiki) to learn more about the language and its features.\n\n\u0026nbsp;\n\n---\n\n\u003ch2 align=\"center\"\u003eCheck out the demo presentation \u003ca href=\"https://iamgio.eu/quarkdown/demo\" target=\"_blank\"\u003ehere\u003c/a\u003e\u003c/h3\u003e\n\u003cp align=\"center\"\u003e\nBuilt with Quarkdown itself — \u003ca href=\"demo/demo.qmd\" target=\"_blank\"\u003e\u003cstrong\u003esource code\u003c/strong\u003e\u003c/a\u003e\n\u003cbr\u003e\u003cbr\u003e\n\u003cem\u003e(Desktop view is suggested)\u003c/em\u003e\n\u003c/p\u003e\n\n---\n\n\u0026nbsp;\n\n## Targets\n\n- **HTML**\n  - :white_check_mark: Plain output (default)\n  - :white_check_mark: Slides \u003csup\u003evia [reveal.js](https://revealjs.com)\u003c/sup\u003e\n  - :white_check_mark: Paged (books, articles) \u003csup\u003evia [paged.js](https://pagedjs.org)\u003c/sup\u003e  \n    *Paged documents require a webserver to render in the browser. See the [`-p`](#options) option below.*\n\n- **PDF**\n  - :white_check_mark: All document types and features supported by HTML are also supported when exporting to PDF.\n  - Check the wiki's [PDF export](https://github.com/iamgio/quarkdown/wiki/pdf-export) page to learn more.\n\nThe desired document type can be set by calling the [`.doctype` function](https://github.com/iamgio/quarkdown/wiki/document-metadata) within the source itself:\n- `.doctype {slides}`\n- `.doctype {paged}`\n\n## Comparison\n\n|                       |     Quarkdown      |      Markdown      |       LaTeX        |      AsciiDoc      |        MDX         |\n|-----------------------|:------------------:|:------------------:|:------------------:|:------------------:|:------------------:|\n| Concise and readable  | :white_check_mark: | :white_check_mark: |        :x:         | :white_check_mark: | :white_check_mark: |\n| Full document control | :white_check_mark: |        :x:         | :white_check_mark: |        :x:         |        :x:         |\n| Scripting             | :white_check_mark: |        :x:         |      Partial       |        :x:         | :white_check_mark: |\n| Book/article export   | :white_check_mark: |        :x:         | :white_check_mark: | :white_check_mark: |    Third-party     |\n| Presentation export   | :white_check_mark: |        :x:         | :white_check_mark: | :white_check_mark: |    Third-party     |\n| Targets               |     HTML, PDF      |        HTML        |        PDF         |  HTML, PDF, ePub   |        HTML        |\n\n\u003ctable\u003e\n  \u003cthead\u003e\n    \u003ctr\u003e\n      \u003cth\u003eLaTeX\u003c/th\u003e\n      \u003cth\u003eQuarkdown\u003c/th\u003e\n    \u003c/tr\u003e\n  \u003c/thead\u003e\n  \u003ctbody\u003e\n    \u003ctr\u003e\n      \u003ctd\u003e\n\n```latex\n\\tableofcontents\n\n\\section{Section}\n\n\\subsection{Subsection}\n\n\\begin{enumerate}\n    \\item \\textbf{First} item\n    \\item \\textbf{Second} item\n\\end{itemize}\n\n\\begin{center}\n    This text is \\textit{centered}.\n\\end{center}\n\n\\begin{figure}[!h]\n    \\centering\n    \\begin{subfigure}[b]\n        \\includegraphics[width=0.3\\linewidth]{img1.png}\n    \\end{subfigure}\n    \\begin{subfigure}[b]\n        \\includegraphics[width=0.3\\linewidth]{img2.png}\n    \\end{subfigure}\n    \\begin{subfigure}[b]\n        \\includegraphics[width=0.3\\linewidth]{img3.png}\n    \\end{subfigure}\n\\end{figure}\n```\n\n\u003c/td\u003e\n\u003ctd\u003e\n\n```markdown\n.tableofcontents\n\n# Section\n\n## Subsection\n\n1. **First** item\n2. **Second** item\n\n.center\n    This text is _centered_.\n\n.row alignment:{spacebetween}\n    ![Image 1](img1.png)\n\n    ![Image 2](img2.png)\n    \n    ![Image 3](img3.png)\n```\n\n\u003c/td\u003e\n\u003c/tr\u003e\n\u003c/tbody\u003e\n\u003c/table\u003e\n\n\u0026nbsp;\n\n## Installation\n\nDownload `quarkdown.zip` from the [releases](https://github.com/iamgio/quarkdown/releases) page or build it yourself with `gradlew distZip`, and unzip it.    \nIf you'd rather keep it minimal, `gradlew build` produces only the JAR file.\n\n- The `bin` directory contains the executable scripts. Optionally, add it to your `PATH` to access Quarkdown more easily.\n- The `lib/qmd` directory contains `.qmd` libraries that can be imported into a project.\n\nJava 17 or higher is required.\n\n## Getting started\n\n### Creating a project\n\nRunning **`quarkdown create [directory]`** will launch the prompt-based project wizard, making it quicker than ever\nto set up a new Quarkdown project, with all [metadata](https://github.com/iamgio/quarkdown/wiki/document-metadata) and initial content already present.\n\nFor more information about the project creator, check out its [wiki page](https://github.com/iamgio/quarkdown/wiki/cli%3A-project-creator).\n\nAlternatively, you may manually create a `.qmd` source file and start from there.\n\n### Compiling\n\nRunning **`quarkdown c file.qmd`** will compile the given file and save the output to file.\n\n\u003e If the project is composed by multiple source files, the target file must be the root one, i.e. the one that includes the other files.\n\u003e\n\u003e - [How to include other files?](https://github.com/iamgio/quarkdown/wiki/including-other-quarkdown-files)\n\nIf you would like to familiarize yourself with Quarkdown instead, `quarkdown repl` lets you play with an interactive REPL mode.\n\n#### Options\n\n- **`-o \u003cdir\u003e`** or **`--output \u003cdir\u003e`**: sets the directory of the output files. If unset, defaults to `./output`.\n\n- **`-p`** or **`--preview`**: enables automatic content reloading after compiling.  \n  If a [webserver](https://github.com/iamgio/quarkdown/wiki/cli%3A-webserver) is not running yet, it is started and the document is opened in the default browser.  \n  This is required in order to render paged documents in the browser.\n\n- **`-w`** or **`--watch`**: recompiles the source everytime a file from the source directory is changed.  \n  \n\u003e [!TIP]\n\u003e Combine `-p -w` to achieve ***live preview***!\n\n- **`--pdf`**: produces a PDF file. Learn more in the wiki's [*PDF export*](https://github.com/iamgio/quarkdown/wiki/pdf-export) page.\n\n- `--server-port \u003cport\u003e`: optional customization of the local webserver's port. Defaults to `8089`.\n\n- `-l \u003cdir\u003e` or `--libs \u003cdir\u003e`: sets the directory where external libraries can be loaded from. If unset, defaults to `\u003cinstall dir\u003e/lib/qmd`. [(?)](https://github.com/iamgio/quarkdown/wiki/importing-external-libraries)\n\n- `--pretty`: produces pretty output code. This is useful for debugging or to read the output code more easily,\n  but it should be disabled in production as the results might be visually affected.\n\n- `--clean`: deletes the content of the output directory before producing new files. Destructive operation.\n\n- `--strict`: forces the program to exit if an error occurs. When not in strict mode, errors are shown as boxes in the document.\n\n- `--no-media-storage`: turns the media storage system off. [(?)](https://github.com/iamgio/quarkdown/wiki/media-storage)\n\n- `-Dloglevel=\u003clevel\u003e` (JVM property): sets the log level. If set to `warning` or higher, the output content is not printed out.\n\n### Mock document\n\n\u0026nbsp;\n\n\u003cp align=\"center\"\u003e\n  \u003cimg width=\"550\" src=\"https://raw.githubusercontent.com/iamgio/quarkdown/project-files/images/mock-demo.png\" alt=\"Mock document demo\"\u003e\n\u003c/p\u003e\n\n***Mock***, written in Quarkdown, is a comprehensive collection of visual elements offered by the language,\nmaking it ideal for exploring and understanding its key features — all while playing and experimenting hands-on with a concrete outcome in the form of pages or slides.\n\n- The document's source files are available in the [`mock`](mock) directory, and can be compiled via `quarkdown c mock/main.qmd -p`.\n- The PDF artifacts generated for all possible theme combinations are available and can be viewed in the [`generated`](https://github.com/iamgio/quarkdown/tree/generated/pdf/mock) branch.  \n\n## Concept\n\nThe logo resembles the original [Markdown icon](https://github.com/dcurtis/markdown-mark), with focus on Quarkdown's completeness,\nrichness of features and customization options, emphasized by the revolving arrow all around the sphere.\n\n\u003cp align=\"center\"\u003e\n  \u003cpicture\u003e\n    \u003csource media=\"(prefers-color-scheme: dark)\" srcset=\"https://raw.githubusercontent.com/iamgio/quarkdown/project-files/images/ticon-light.svg\"\u003e\n    \u003csource media=\"(prefers-color-scheme: light)\" srcset=\"https://raw.githubusercontent.com/iamgio/quarkdown/project-files/images/ticon-dark.svg\"\u003e\n    \u003cimg alt=\"Quarkdown icon\" src=\"https://raw.githubusercontent.com/iamgio/quarkdown/project-files/images/ticon-dark.svg\"\u003e\n  \u003c/picture\u003e\n\u003c/p\u003e\n\nWhat could be mistaken for a planet is actually a **quark** or, more specifically, a **down quark**,\nan elementary particle that is a major constituent of matter: they give life to every complex structure we know of,\nwhile also being one of the lightest objects in existence.\n\nThis is, indeed, the concept **Quarkdown** is built upon. ","funding_links":[],"categories":["知识库软件/笔记软件/思维构造工具","Kotlin","语法规范与扩展","compiler","⚡ Productivity"],"sub_categories":["HUD","Resources"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiamgio%2Fquarkdown","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fiamgio%2Fquarkdown","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiamgio%2Fquarkdown/lists"}