{"id":22758827,"url":"https://github.com/getcuia/cusser","last_synced_at":"2025-04-14T18:21:31.910Z","repository":{"id":37856977,"uuid":"430844871","full_name":"getcuia/cusser","owner":"getcuia","description":"🤬 A curses wrapper that understands ANSI escape code sequences","archived":false,"fork":false,"pushed_at":"2024-07-25T19:34:45.000Z","size":352,"stargazers_count":9,"open_issues_count":12,"forks_count":5,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-28T06:51:07.753Z","etag":null,"topics":["ansi","ansi-escape-codes","cli","command-line","console","cuia","curses","cusser","ncurses","pdcurses","python","terminal","tui"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/cusser/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/getcuia.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-11-22T19:49:25.000Z","updated_at":"2024-04-09T08:37:36.000Z","dependencies_parsed_at":"2023-02-18T07:35:29.765Z","dependency_job_id":null,"html_url":"https://github.com/getcuia/cusser","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/getcuia%2Fcusser","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/getcuia%2Fcusser/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/getcuia%2Fcusser/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/getcuia%2Fcusser/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/getcuia","download_url":"https://codeload.github.com/getcuia/cusser/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248933349,"owners_count":21185461,"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":["ansi","ansi-escape-codes","cli","command-line","console","cuia","curses","cusser","ncurses","pdcurses","python","terminal","tui"],"created_at":"2024-12-11T08:16:02.974Z","updated_at":"2025-04-14T18:21:31.886Z","avatar_url":"https://github.com/getcuia.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![PyPI](https://img.shields.io/pypi/v/cusser)](https://pypi.org/project/cusser/)\n[![Python package](https://github.com/getcuia/cusser/actions/workflows/python-package.yml/badge.svg)](https://github.com/getcuia/cusser/actions/workflows/python-package.yml)\n[![PyPI - License](https://img.shields.io/pypi/l/cusser)](https://github.com/getcuia/cusser/blob/main/LICENSE)\n\n# [cusser](https://github.com/getcuia/cusser#readme) 🤬\n\n\u003cdiv align=\"center\"\u003e\n    \u003cimg class=\"hero\" src=\"https://github.com/getcuia/cusser/raw/main/banner.jpg\" alt=\"cusser\" width=\"33%\" /\u003e\n\u003c/div\u003e\n\n\u003e A curses wrapper that understands ANSI escape code sequences\n\ncusser is a lightweight Python package for teaching\n[curses](https://docs.python.org/3/library/curses.html) how to use\n[ANSI escape code sequences](https://en.wikipedia.org/wiki/ANSI_escape_code). It\nworks by wrapping the curses standard window object and intercepting escape code\nsequences.\n\n## Features\n\n-   ♻️ Easily integrate with the\n    [standard `curses` module](https://docs.python.org/3/library/curses.html)\n-   🕹️ Use the same escape code sequences\n    [as you would with Colorama](https://github.com/tartley/colorama#recognised-ansi-sequences)\n-   🖍️ Only one dependency: [stransi](https://github.com/getcuia/stransi) (for\n    actuallly parsing escape code sequences)\n-   🐍 Python 3.8+\n\n## Installation\n\n```console\n$ pip install cusser\n```\n\n## Usage\n\n```python\nIn [1]: import curses\n\nIn [2]: from cusser import Cusser\n\nIn [3]: def app(stdscr) -\u003e None:\n   ...:     \"\"\"Start a new application.\"\"\"\n   ...:     if not isinstance(stdscr, Cusser):\n   ...:         stdscr = Cusser(stdscr)\n   ...:\n   ...:     ultra_violet = (100, 83, 148)\n   ...:     x, y = 34, 12\n   ...:     stdscr.addstr(\n   ...:         f\"\\033[2J\\033[{x};{y}H\"\n   ...:         \"\\033[1;32mHello \"\n   ...:         f\"\\033[;3;38;2;{';'.join(map(str, ultra_violet))}m\"\n   ...:         \"cusser\"\n   ...:         \"\\033[m 🤬!\"\n   ...:     )\n   ...:     stdscr.refresh()\n   ...:     stdscr.getch()\n   ...:\n\nIn [4]: curses.wrapper(app)\n\n```\n\n![Screenshot](https://github.com/getcuia/cusser/raw/main/screenshot.png)\n\n## Credits\n\n[Photo](https://github.com/getcuia/cusser/raw/main/banner.jpg) by\n[Gwendal Cottin](https://unsplash.com/@gwendal?utm_source=unsplash\u0026utm_medium=referral\u0026utm_content=creditCopyText)\non\n[Unsplash](https://unsplash.com/?utm_source=unsplash\u0026utm_medium=referral\u0026utm_content=creditCopyText).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgetcuia%2Fcusser","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgetcuia%2Fcusser","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgetcuia%2Fcusser/lists"}