{"id":18668643,"url":"https://github.com/kstenschke/lspng","last_synced_at":"2025-11-06T16:30:37.981Z","repository":{"id":147562858,"uuid":"369566551","full_name":"kstenschke/lspng","owner":"kstenschke","description":"Sort PNGs by Luminance","archived":false,"fork":false,"pushed_at":"2021-10-03T08:32:55.000Z","size":3757,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-12-27T18:30:35.462Z","etag":null,"topics":["cli","image","luminance","picture","png","sort","tool"],"latest_commit_sha":null,"homepage":"","language":"C++","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/kstenschke.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.txt","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}},"created_at":"2021-05-21T14:46:11.000Z","updated_at":"2021-10-03T08:32:57.000Z","dependencies_parsed_at":"2023-04-10T20:54:50.880Z","dependency_job_id":null,"html_url":"https://github.com/kstenschke/lspng","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kstenschke%2Flspng","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kstenschke%2Flspng/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kstenschke%2Flspng/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kstenschke%2Flspng/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kstenschke","download_url":"https://codeload.github.com/kstenschke/lspng/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239498776,"owners_count":19648930,"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":["cli","image","luminance","picture","png","sort","tool"],"created_at":"2024-11-07T08:44:26.511Z","updated_at":"2025-02-18T15:36:49.698Z","avatar_url":"https://github.com/kstenschke.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Build Status](https://api.travis-ci.com/kstenschke/lspng.svg?branch=master)](https://travis-ci.com/kstenschke/lspng)\n[![CodeFactor](https://www.codefactor.io/repository/github/kstenschke/lspng/badge)](https://www.codefactor.io/repository/github/kstenschke/lspng)\n\n\n# lspng - List PNG attributes (luminance, pixel size) into their filenames\n\n## Table of Contents\n\n* [What does it do?](#what-does-it-do)\n* [Command: ``--version`` or ``-v``](#command---version-or--v)\n* [Option: ``--desc`` or ``-d``](#option---desc-or--d)\n* [Option: ``--amount_digits_min=`` or ``-a=``](#option---amount_digits_min-or--a)\n* [Option: ``--numeric_only`` or ``-n``](#option---amount_digits_min-or--a)\n* [Option: ``--append_luminance`` or ``-l``](#option---append_luminance-or--l)\n* [Option: ``--append_px_wid_and_hgt`` or ``-p``](#option---append_px_wid_and_hgt-or--p)\n* [Build from source](#build-from-source)\n* [Install](#install)\n* [Conventions](#conventions)\n* [Changelog](#changelog)\n* [Used third party libraries](#used-third-party-libraries)\n* [Author and License](#author-and-license)\n\n\n## What does it do?\n\nlspng analyzes and renames PNG image files, so their filenames allow to sort \nPNGs by luminance. Additionally the pixel size (width x height) of images can be\nadded into their filename.\n\n\n## Command: ``--version`` or ``-v``\n\nPrint information about installed version of ``lspng``, its license and\nauthor(s). \n\n\n## Option: ``--desc`` or ``-d``\n\nBy default lspng sorts PNGs ordered from lightest to darkest.\nRunning ``lspng -d`` will sort/rename the files descending instead, that is from\ndarkest to lightest.\n\n\n## Option: ``--amount_digits_min=`` or ``-a=``\n\nRunning ``lspng -a=3`` will set a minimum prefix length of three digits.\nInstead of e.g. `0_foo.png` the lightest PNG image than will be named \n`000_foo.png`.\n\n\n## Option: ``--numeric_only`` or ``-n``\n\nRunning ``lspng -n`` will omit the original filenames and rename png files\nnumeric only. Instead of e.g. `0_foo.png` the lightest PNG image than will be named \n`0.png`.\n\n\n## Option: ``--append_luminance`` or ``-l``\n\nRunning ``lspng -nl`` - the ``n`` will instruct lspng to omit the original \nfilename and name png files numerical. The ``l`` instructs lspng to append\nthe image's lightness value, resulting in a filename like: `0_050.png`.  \nThe luminance value in percent ranges from ``000`` (=white) to ``100`` (=black).\n\n\n## Option: ``--append_px_wid_and_hgt`` or ``-p``\n\nRunning ``lspng -nlp`` - the ``n`` will instruct lspng to omit the original \nfilename and name png files numerical. The ``l`` instructs lspng to append\nthe image's lightness value and the ``p`` will instruct lspng to append the \nimage's width/height dimension, resulting in a filename like: `0_050_320x240.png`.  \nThe luminance value in percent ranges from ``000`` (=white) to ``100`` (=black).\n\n\n## Build from source\n\nInitially fetch dependencies:``git submodule update --init --recursive``\n  \nThan: ``cmake CMakeLists.txt; make``\n\n\n## Install\n\nBuild from source, than: ``sudo make install``\n\n\n## Conventions\n\nThe source code of **lspng** follows the Google C++ Style Guide, \nsee: https://google.github.io/styleguide/cppguide.html    \n\n**lspng** follows the [Semantic Versioning](https://semver.org) Scheme.\n\n\n## Changelog\n\nSee [CHANGELOG.md](CHANGELOG.md)\n\n\n## Used third party libraries\n\n| Application                          | License                                                                                                                                                                                                                            |\n| ------------------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| [The CImg Library](https://cimg.eu/) | Distributed under the [CeCILL-C](http://www.cecill.info/licences/Licence_CeCILL-C_V1-en.txt) (close to the GNU LGPL) or [CeCILL](http://www.cecill.info/licences/Licence_CeCILL_V2-en.txt) (compatible with the GNU GPL) licenses. |\n\n\n## Author and License\n\n**lspng** was written by Kay Stenschke and is licensed under the \n[GNU General Public License V3.0](https://www.gnu.org/licenses/licenses.html#GPL)  \n\n```\nPermissions of this strong copyleft license are conditioned on making available \ncomplete source code of licensed works and modifications, which include larger \nworks using a licensed work, under the same license. Copyright and license \nnotices must be preserved. Contributors provide an express grant of patent \nrights.\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkstenschke%2Flspng","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkstenschke%2Flspng","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkstenschke%2Flspng/lists"}