{"id":18081950,"url":"https://github.com/vindarel/progressons","last_synced_at":"2025-04-05T22:29:15.035Z","repository":{"id":67525198,"uuid":"316275492","full_name":"vindarel/progressons","owner":"vindarel","description":"A progress bar.","archived":false,"fork":false,"pushed_at":"2025-01-02T13:59:25.000Z","size":44,"stargazers_count":14,"open_issues_count":2,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-02-12T04:17:15.249Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Common Lisp","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/vindarel.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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},"funding":{"github":["vindarel"],"ko_fi":"vindarel"}},"created_at":"2020-11-26T15:51:36.000Z","updated_at":"2025-01-02T13:59:29.000Z","dependencies_parsed_at":null,"dependency_job_id":"c772313e-71c1-49ea-ae48-0b5a7587d4a3","html_url":"https://github.com/vindarel/progressons","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vindarel%2Fprogressons","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vindarel%2Fprogressons/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vindarel%2Fprogressons/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vindarel%2Fprogressons/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vindarel","download_url":"https://codeload.github.com/vindarel/progressons/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247411241,"owners_count":20934650,"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":[],"created_at":"2024-10-31T13:17:30.090Z","updated_at":"2025-04-05T22:29:15.019Z","avatar_url":"https://github.com/vindarel.png","language":"Common Lisp","readme":"[![Quicklisp](http://api.quickdocs.org/badge/progressons.svg)](http://quickdocs.org/progressons/)\n\n# Progressons\n\nDisplay a progress bar on one line.\n\n    [1437/1437]██████████████████████████████████████████████████████████████████████████[100%]\n\n- [X] Support for real and dumb terminal windows\n  - on the terminal, it correctly updates the progress percent and the number of items. On a dumb terminal like Emacs Slime, it can't erase the previous step to update the numbers, so it simply prints one progress indicator after the other, still on one line.\n\nStatus: usable for simple cases, adds too much overhead with large datasets, work in progress, the API might change.\n\n## Installation\n\nThis library is on [Ultralisp](https://ultralisp.org/github),\n\nand on Quicklisp since the 2024-10 release.\n\n## Usage\n\nInstantiate with `(progressbar data)` and call `(step!)` at each iteration.\n\n~~~lisp\n(loop for elt in (progressbar (list 1 2 3 4 5))\n   do (do-something-with elt)\n      (sleep 0.1)\n      (step!))\n~~~\n\n`data` is a list of data, or an integer specifying the number of iterations.\n\nUse the bar character you want with `:bar \"\u003e\"` (a character or a string of one element):\n\n~~~lisp\n(loop for line in (progressbar (list 1 2 3 4 5) :bar \"\u003e\") do (sleep 0.3) (step!))\n\n[0/5]\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e[100%]\n~~~\n\nUse `(progressbar data :rainbow t)` for some colors:\n\n![](progressons-colorful.png)\n\nbut… that works only on a dumb terminal, too bad (we don't see the progress on a real terminal).\n\nRun the demo:\n\n    sbcl --load demo.lisp\n    # aka make demo\n\nManual progress:\n\n```\nCL-USER\u003e (progressbar (list 1 2 3 4 5))\n(1 2 3 4 5)\n#\u003cPROGRESS BAR, length 5, step 16\u003e\n\nCL-USER\u003e (step!)\n\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e                                                                [20]\n\nCL-USER\u003e  (step!)\n\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e                                                [40]\n[…]\nCL-USER\u003e  (step!)\n\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e\u003e[100]\n```\n\n`step!` takes an optional progressbar object as argument.\n\nWe'd like to remove the need of calling `(step!)` eventually.\n\n\n## Do it yourself\n\nThe guist of a progress bar is to print a string, then erase it to\nprint a longer one by printing a backspace character `(write-char #\\return)`.\n\n## See also\n\nhttps://github.com/sirherrbatka/cl-progress-bar (oops, it's probably OK for my use case and more complete)\n\nhttps://40ants.com/lisp-project-of-the-day/2020/04/0034-cl-progress-bar.html\n\nLicence: MIT\n","funding_links":["https://github.com/sponsors/vindarel","https://ko-fi.com/vindarel"],"categories":["Interfaces to other package managers"],"sub_categories":["Third-party APIs"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvindarel%2Fprogressons","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvindarel%2Fprogressons","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvindarel%2Fprogressons/lists"}