-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathoutput.epub
More file actions
1 lines (1 loc) · 6.33 KB
/
output.epub
File metadata and controls
1 lines (1 loc) · 6.33 KB
1
<h1>TextScribe - Markdown Converter</h1><p><img src="https://i.imgur.com/FU0mh9C.png" alt="logo" /></p><p>The Markdown Converter is a robust command-line utility built with Rust. It's designed to transform Markdown files into HTML, EPUB & PDF format effortlessly. With the power of the 'pulldown-cmark' crate, it ensures accurate parsing and rendering of Markdown content.</p><h2>Table of Contents</h2><ul><li><a href="#%F0%9F%8C%9F-features">🌟 Features</a></li><li><a href="#%F0%9F%9A%80-installation">🚀 Installation</a></li><li><a href="#%F0%9F%9B%A0-usage">🛠 Usage</a><ul><li><a href="example">Example</a></li></ul></li><li><a href="#%F0%9F%8E%A8-options">🎨 Options</a></li><li><a href="#%F0%9F%9A%A7-future-roadmap">🚧 Future Roadmap</a></li><li><a href="#%F0%9F%A4%9D-contributing">🤝 Contributing</a></li><li><a href="#%F0%9F%93%9C-license">📜 License</a></li></ul><h2>🌟 Features</h2><ul><li><p><strong>Swift Conversion</strong>: Instantly convert your Markdown files into HTML, PDF & EPUB.</p></li><li><p><strong>Intuitive Interface</strong>: A user-friendly command-line interface powered by the <code>clap</code> crate.</p></li><li><p><strong>Rich Markdown Support</strong>: Supports a wide range of Markdown syntax, including headings, paragraphs, lists, emphasis, links, images (with Base64 embedding), and code blocks.</p></li><li><p><a href="#%F0%9F%8E%A8-options"><strong>Customization Options</strong></a>: Choose specific Markdown features like tables and strikethrough using the <code>pulldown-cmark</code> Options.</p></li><li><p><strong>Flexible Output</strong>: Save the generated HTML or EPUB to a specified location, copy it directly to the clipboard, or preview it in your default web browser.</p></li><li><p><strong>Theming</strong>: Style your HTML output with different themes.</p></li></ul><h2>🚀 Installation</h2><ol><li><p><strong>Setup Rust Environment</strong>: If you haven't installed Rust and Cargo, get them from <a href="https://www.rust-lang.org/">Rust's official website</a>.</p></li><li><p><strong>Clone the Repository</strong>:</p><pre><code class="language-console">git clone https://github.com/arncv/TextScribe.git</code></pre></li><li><p><strong>Navigate to the Project Directory</strong>:</p><pre><code class="language-console">cd TextScribe</code></pre></li><li><p><strong>Compile the Project</strong>:</p><pre><code class="language-console">cargo build --release</code></pre></li></ol><h2>🛠 Usage</h2><p>To convert your Markdown to HTML or EPUB, use the following command:</p><pre><code class="language-console">cargo run --release -- -i <input-file> [-o <output-file>] [--theme <theme-name>] [--clipboard] [--browser] [--epub]</code></pre><ul><li><code><input-file></code>: Path to your Markdown file.</li><li><code><output-file></code>: (Optional) Path for the HTML output. If not provided and neither clipboard nor browser options are used, an error will be prompted.</li><li><code>--theme <theme-name></code>: Choose a theme (options: default, dark, light).</li><li><code>--clipboard</code>: Copy the generated HTML directly to the clipboard.</li><li><code>--browser</code>: Preview the generated HTML in your default web browser.</li><li><code>--epub</code>: Generate an EPUB file. Perfect for readers.</li></ul><h3><strong>Example:</strong></h3><p>Convert <code>example.md</code> to HTML using the dark theme and save it as <code>output.html</code>:</p><pre><code class="language-console">cargo run --release -- -i example.md -o output.html --theme dark</code></pre><p>To copy the output directly to the clipboard:</p><pre><code class="language-console">cargo run --release -- -i example.md --clipboard</code></pre><p>To preview the output in your default web browser:</p><pre><code class="language-console">cargo run --release -- -i example.md --browser</code></pre><p>Convert <code>example.md</code> to EPUB using the dark theme and save it as <code>output.epub</code>:</p><pre><code class="language-console">cargo run --release -- -i example.md -o output.epub --theme dark --epub</code></pre><h2>🎨 Options</h2><ul><li><p><strong>Theming</strong>: Style your HTML output.</p><pre><code class="language-console">cargo run --release -- -i <input-file> -o <output-file> --theme <theme-name></code></pre></li><li><p><strong>Tables</strong>: Enable table formatting in your Markdown.</p><pre><code class="language-console">cargo run --release -- -i <input-file> -o <output-file> --tables</code></pre></li><li><p><strong>Strikethrough</strong>: Enable strikethrough formatting.</p><pre><code class="language-console">cargo run --release -- -i <input-file> -o <output-file> --strikethrough</code></pre></li><li><p><strong>Clipboard Output</strong>: Copy the generated HTML to the clipboard.</p><pre><code class="language-console">cargo run --release -- -i <input-file> --clipboard</code></pre></li><li><p><strong>Browser Preview</strong>: View the generated HTML in your default web browser.</p><pre><code class="language-console">cargo run --release -- -i <input-file> --browser</code></pre></li></ul><h2>🚧 Future Roadmap</h2><ul><li>✅ <strong>Support more image types</strong>: Support for more image types ; GIFs, PNG, JPEG.</li><li>✅ <strong>Improved Error Handling</strong>: Improved functionality & logging for errors.</li><li>✅ <strong>PDF Conversion</strong>: Integrate functionality to convert the generated HTML into PDF format.</li><li><ul><li>[ ] <strong>Extended Theming</strong>: Introduce more themes and customization options for the HTML output.</li></ul></li><li><ul><li>[ ] <strong>Interactive GUI</strong>: Develop a graphical user interface for users who prefer GUI over CLI.</li></ul></li><li><ul><li>[ ] <strong>Enhanced Image Support</strong>: Improve image embedding with options for resizing, alignment, and captions.</li></ul></li></ul><p>We're always open to suggestions and feedback. If you have an idea that's not listed here, please share it with us!</p><h2>🤝 Contributing</h2><p>Contributions are always welcome! Whether it's a feature request, bug fix, or a new idea, feel free to submit a pull request or open an issue. Let's enhance this tool together!Be sure to read <a href="CONTRIBUTING.md">CONTRIBUTING</a> file to know about more contributions details.</p><h2>📜 License</h2><p>This project is licensed under the <a href="LICENSE">MIT License</a>.</p>