{"id":18774736,"url":"https://github.com/firefly-cpp/thumbnails-readme","last_synced_at":"2025-07-22T21:33:59.814Z","repository":{"id":65236840,"uuid":"580534549","full_name":"firefly-cpp/thumbnails-readme","owner":"firefly-cpp","description":"Create thumbnails","archived":false,"fork":false,"pushed_at":"2024-09-14T11:50:46.000Z","size":27918,"stargazers_count":2,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-06-18T12:52:07.683Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/firefly-cpp.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","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":"2022-12-20T20:00:27.000Z","updated_at":"2024-09-14T11:50:50.000Z","dependencies_parsed_at":"2024-04-25T15:51:29.471Z","dependency_job_id":"fc03a94d-b9d4-4dfb-9185-2e55debc12d0","html_url":"https://github.com/firefly-cpp/thumbnails-readme","commit_stats":{"total_commits":64,"total_committers":6,"mean_commits":"10.666666666666666","dds":0.5,"last_synced_commit":"96dffe0c62e0241c5f31a856f9630173656353f4"},"previous_names":[],"tags_count":16,"template":false,"template_full_name":null,"purl":"pkg:github/firefly-cpp/thumbnails-readme","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firefly-cpp%2Fthumbnails-readme","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firefly-cpp%2Fthumbnails-readme/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firefly-cpp%2Fthumbnails-readme/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firefly-cpp%2Fthumbnails-readme/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/firefly-cpp","download_url":"https://codeload.github.com/firefly-cpp/thumbnails-readme/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/firefly-cpp%2Fthumbnails-readme/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266578628,"owners_count":23951148,"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","status":"online","status_checked_at":"2025-07-22T02:00:09.085Z","response_time":66,"last_error":null,"robots_txt_status":null,"robots_txt_updated_at":null,"robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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-11-07T19:39:12.823Z","updated_at":"2025-07-22T21:33:59.794Z","avatar_url":"https://github.com/firefly-cpp.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg alt=\"logo\" width=\"300\" src=\".github/images/logo_background.png\"\u003e\n\u003c/p\u003e\n\n\u003ch1 align=\"center\"\u003e\n  thumbnails-readme\n\u003c/h1\u003e\n\n\u003ch2 align=\"center\"\u003e\n  Create thumbnails for raster and vector images in parent and its subdirectories and append them to the README.md file\n\u003c/h2\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg alt=\"PyPI Version\" src=\"https://img.shields.io/pypi/v/thumbnails-readme.svg\"\u003e\n  \u003cimg alt=\"PyPI - Python Version\" src=\"https://img.shields.io/pypi/pyversions/thumbnails-readme.svg\"\u003e\n  \u003cimg alt=\"PyPI - Downloads\" src=\"https://img.shields.io/pypi/dm/thumbnails-readme.svg\"\u003e\n  \u003ca href=\"https://repology.org/project/python:thumbnails-readme/versions\"\u003e\n    \u003cimg alt=\"Packaging status\" src=\"https://repology.org/badge/tiny-repos/python:thumbnails-readme.svg\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://pepy.tech/project/thumbnails-readme\"\u003e\n    \u003cimg alt=\"Downloads\" src=\"https://pepy.tech/badge/thumbnails-readme\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/firefly-cpp/thumbnails-readme/blob/master/LICENSE\"\u003e\n    \u003cimg alt=\"GitHub License\" src=\"https://img.shields.io/github/license/firefly-cpp/thumbnails-readme.svg\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg alt=\"GitHub repo size\" src=\"https://img.shields.io/github/repo-size/firefly-cpp/thumbnails-readme\"\u003e\n  \u003cimg alt=\"GitHub Commit Activity\" src=\"https://img.shields.io/github/commit-activity/w/firefly-cpp/thumbnails-readme.svg\"\u003e\n  \u003ca href='http://isitmaintained.com/project/firefly-cpp/thumbnails-readme \"Average time to resolve an issue\"'\u003e\n    \u003cimg alt=\"Average time to resolve an issue\" src=\"http://isitmaintained.com/badge/resolution/firefly-cpp/thumbnails-readme.svg\"\u003e\n  \u003c/a\u003e\n  \u003ca href='http://isitmaintained.com/project/firefly-cpp/thumbnails-readme \"Percentage of issues still open\"'\u003e\n    \u003cimg alt=\"Percentage of issues still open\" src=\"http://isitmaintained.com/badge/open/firefly-cpp/thumbnails-readme.svg\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"#-github-action\"\u003e🚀 GitHub Action\u003c/a\u003e •\n  \u003ca href=\"#-how-does-it-work\"\u003e💡 How does it work?\u003c/a\u003e •\n  \u003ca href=\"#-installation\"\u003e📦 Installation\u003c/a\u003e •\n  \u003ca href=\"#-additional-dependencies\"\u003e🔗 Additional dependencies\u003c/a\u003e •\n  \u003ca href=\"#-example\"\u003e📓 Example\u003c/a\u003e •\n  \u003ca href=\"#-use-cases\"\u003e📂 Use Cases\u003c/a\u003e •\n  \u003ca href=\"#-license\"\u003e🔑 License\u003c/a\u003e •\n  \u003ca href=\"#-thumbnails\"\u003e📷 Thumbnails\u003c/a\u003e\n\u003c/p\u003e\n\nThe `thumbnails-readme` package is a simple library devoted to automatically generating thumbnails from a directory. It is explicitly designed to create thumbnails from Git folders. The thumbnails are shown in the README file of that Git folder. 📁🌐📸\n\n### 🔄 Multi-page PDFs are turned into .gif thumbnails\n\nCurrent supported filetype extensions are: `.bmp`, `.gif`, `.ico`, `jpeg`, `.jpg`, `.png`, `.tga`, `.tiff`, `.webp`, `.pdf`, and `.svg`\n\n## 🚀 GitHub Action\n\nSee the associated GitHub Action in the following repository: [thumbnails-readme-action](https://github.com/KukovecRok/thumbnails-readme-action).\n\n## 💡 How does it work?\n\nIn the first step the program finds graphical material in your directories:\n* ['fig1.pdf', 'fig2.pdf', 'fig3.pdf', 'fig4.pdf']\n\nIn the second step the program generates thumbnails for each material identified in folders.\n\n![2023-01-05 10_54_06-000245](https://user-images.githubusercontent.com/33880044/212469322-e4fe49af-404d-40cd-85f8-63fd3eee162d.png)\n\nIn the third step the program appends thumbnails to the README file.\n\n![thumbnails-readme-md-image](https://user-images.githubusercontent.com/33880044/224533101-11618c49-61b5-4b6a-bccd-5a1164430bca.png)\n\n## 📦 Installation\n\nTo install `thumbnails-readme` with pip, use:\n\n```sh\npip install thumbnails-readme\n```\n\nTo install `thumbnails-readme` directly from the source code, use:\n\n```sh\n$ git clone https://github.com/firefly-cpp/thumbnails-readme.git\n$ cd thumbnails-readme\n$ poetry build\n$ python setup.py install\n```\n\nTo install `thumbnails-readme` on Alpine Linux, please use:\n\n```sh\n$ apk add py3-thumbnails-readme\n```\n\nTo install `thumbnails-readme` on Arch Linux, use an [AUR helper](https://wiki.archlinux.org/title/AUR_helpers):\n\n```sh\n$ yay -Syyu python-thumbnails-readme\n```\n\n## 🔗 Additional dependencies\n\n### Windows\nWindows users have to download poppler for Windows. Add poppler path in your Python file (see the main example).\n\n``` poppler_path = path/to/your/poppler/bin/ ```\n\nFor example: ```poppler_path = C:/Program Files/poppler-0.68.0/bin```\n\n### Linux\nLinux's users can install poppler-utils from the main repositories.\n\n## 📓 Examples\n\n### Examples of Usage\n\n```python\n# Maximum thumbnail size - lower the number, smaller the thumbnail\nMAX_SIZE = (128, 128)\n\n# PDF quality, lower the number, lower the quality\npdf_quality = 15\n\n# Skiplist - which directories to ignore\nskiplist = (\n  \".git\",\n)\n\n# Path to your directory\npath = os.getcwd()\npath = os.path.dirname(path)\n\n# Path to the folder, you want new thumbnails to be placed in\npath_to_thumbnails_folder = Path(path + \"/image_thumbnails\")\n\n# Path to README.md file to be written to\npath_to_readme = Path(path + \"/README.md\")\n```\n\n### Run the script\n\n``` python\n# Prepare thumbnails folder (check if exists, delete old thumbnails and create new ones)\nthumbnails_readme.prepare_thumbnails_folder(path_to_thumbnails_folder)\n\n# Prepare README.md file (check if exists, delete last modifications and place newly generated ones)\nthumbnails_readme.prepare_readme(path_to_readme)\n\n# Generate thumbnails\nthumbnails_readme.crawl(path, path_to_readme, path_to_thumbnails_folder, MAX_SIZE, pdf_quality, skiplist, poppler_path)\n```\n## 📂 Use Cases\n\n- [https://github.com/firefly-cpp/figures](https://github.com/firefly-cpp/figures)\n- [https://github.com/firefly-cpp/posters](https://github.com/firefly-cpp/posters)\n\n## 🔑 License\n\nThis package is distributed under the BSD-3-Clause license. This license can be found online at \u003chttp://www.opensource.org/licenses/bsd-3-clause/\u003e.\n\n## Disclaimer\n\nThis framework is provided as-is, and there are no guarantees that it fits your purposes or that it is bug-free. Use it at your own risk!\n\n## 📷 Thumbnails\n\n[![example-long](/image_thumbnails/pdf_animation_example-long.gif)](tests/example-long.pdf)\n[![example-pdf](/image_thumbnails/pdf_example-pdf_thumb.png)](tests/example-pdf.pdf)\n[![example-svg](/image_thumbnails/svg_example-svg_thumb.png)](tests/example-svg.svg)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffirefly-cpp%2Fthumbnails-readme","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffirefly-cpp%2Fthumbnails-readme","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffirefly-cpp%2Fthumbnails-readme/lists"}