Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add feature to generate HTML file #47

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

legosandorigami
Copy link

@legosandorigami legosandorigami commented Jan 31, 2025

@blenderskool Hi,
This PR aims to solve the issue #19 by adding HTML rendering functionality using the minijinja template engine for rendering the HTML.

I chose Minijinja for this task because I am most familiar with the Jinja template engine. I found Minijinja straightforward to use, and it has minimal dependencies.

Here is how the rendered HTML file looks:
pigmnts_readme

Usage

The HTML file can be generated using the following command:

pigmnts flowers/flowers5.png flowers/flowers4.jpg -xnrgq --count 4 --count 4

the flag -g or --html is used to enable HTML output.

Segmentation Fault (Issue #46)

While working on this feature, I encountered a segmentation fault (issue #46) when printing the table to stdout. In my case, the issue was resolved by updating the termion and prettytable-rs dependencies.

I am relatively new to Rust, I would greatly appreciate any feedback. I found working on this project to be super educational, this project is awesome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant