{"id":13598547,"url":"https://github.com/AbhijithAJ/clrprint","last_synced_at":"2025-04-10T09:31:35.315Z","repository":{"id":44868807,"uuid":"279823947","full_name":"AbhijithAJ/clrprint","owner":"AbhijithAJ","description":"Print colorful output in the terminal, idle, cmd, and Windows PowerShell using the same functions.","archived":false,"fork":false,"pushed_at":"2022-11-13T07:13:48.000Z","size":769,"stargazers_count":27,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2024-04-24T16:37:01.243Z","etag":null,"topics":["clrprint","colorprint","colors","cross-platform","debug","debugging","idle","idle-colors","input","no-blocking","powershell","python","python3","terminal","timeout"],"latest_commit_sha":null,"homepage":"","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/AbhijithAJ.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":"2020-07-15T09:24:29.000Z","updated_at":"2023-05-29T07:48:21.000Z","dependencies_parsed_at":"2023-01-22T23:45:25.988Z","dependency_job_id":null,"html_url":"https://github.com/AbhijithAJ/clrprint","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AbhijithAJ%2Fclrprint","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AbhijithAJ%2Fclrprint/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AbhijithAJ%2Fclrprint/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AbhijithAJ%2Fclrprint/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AbhijithAJ","download_url":"https://codeload.github.com/AbhijithAJ/clrprint/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248191725,"owners_count":21062559,"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":["clrprint","colorprint","colors","cross-platform","debug","debugging","idle","idle-colors","input","no-blocking","powershell","python","python3","terminal","timeout"],"created_at":"2024-08-01T17:00:53.547Z","updated_at":"2025-04-10T09:31:30.275Z","avatar_url":"https://github.com/AbhijithAJ.png","language":"Python","funding_links":["https://www.paypal.me/abhijithboppes","https://www.buymeacoffee.com/abhijithboppe"],"categories":["Python"],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003e\n  clrprint v2.0\n\u003cdiv align=\"center\"\u003e\n\n[![Generic badge](https://img.shields.io/badge/Made_By-ABHIJITH_BOPPE-BLUE.svg)](https://www.linkedin.com/in/abhijith-boppe/)  \n[![made-with-python](https://img.shields.io/badge/Made%20with-Python-1f425f.svg)](https://www.python.org/) [![Generic badge](https://img.shields.io/badge/pypi_package-2.0.1-DARKGREEN.svg)](https://pypi.org/project/clrprint/) [![PyPI license](https://img.shields.io/pypi/l/ansicolortags.svg)](https://github.com/AbhijithAJ/clrprint/blob/master/LICENSE) [![PayPal](https://img.shields.io/badge/donate-PayPal-blue.svg)](https://www.paypal.me/abhijithboppes) \n\u003c/div\u003e\n\n\n\u003c/h1\u003e\n \n - Colorful output \n - Work's on IDLE, command prompt, windows powerShell, and terminal\n - Simply input() with clrinput() and print() with clrprint()\n - Basic colors only. Red, green, yellow, blue, purple, and black/white (default)\n - Flexible to print or take input only on demand (on DEBUG)\n - User input timeout feature (This is supported only on interactive shell)\n---\n## ABOUT\n\nThis **clrprint** is developed to print a colorful output on idle, windows power shell and terminal. It has red, blue, green, yellow, purple and black/white (default) colors. \n\nclrinput() includes a timeout feature that returns None if no user input is received within a certain amount of time.\n\n*It prints with default color if given color is not available.*\n\n### Installation\nYou can install clrprint by running the following command\n```\npip install clrprint\n```\n\n**Usage**\n\nIt's as simple as using Python's print() and input() functions.\n\nArgument **clr** to represent color, **debug** to print only when debug=True are added.\n\nclrinput() takes **timeout** argument that returns None if no user input is not received within a certain amount of time.\n\n*Note: **timeout** feature is not supported in IDLE. It is neglected by IDLE if it is passed*\n\nYou can use clrhelp() to print out and see how to use it.\n\nExample Code:\n```python\nfrom clrprint import *\n\nclrprint('text1','text2', clr='r')  # single letter is enough to represent color.\nclrprint('text1_clr1','text2_clr2','text3_clr3','text4_clr4', clr='r,y,g') # prints 3 colors in same line\nclrprint('ERROR:','error information','suggestions 1','suggestion2','suggestion3', clr='r,y,g') # print\n\n#Supported on terminal, command prompt and powershell \ncolord_text = clrit('text1', 'text2', clr='r,g') # returns ASCII coloured text\nprint(colord_text)\nuser_input = clrinput('Choose yes/no?', clr='r', timeout=10) or \"DEFAULT\"  # Take user input in 10 sec else Choose any Default value\nprint(user_input)\n\n```\n\nThe input timeout functionality was inspired by \u003cb\u003e\u003ci\u003e[WereCatf](https://github.com/WereCatf) \u003c/i\u003e \u003c/b\u003e from the project \u003cb\u003e\u003ci\u003e[werecatf](https://github.com/werecatf/pytimedinput/) \u003c/i\u003e\u003c/b\u003e\n\n## Screenshots\nTerminal:\n\n\u003cimg src=\"images/terminal.png\" width=\"100%\"\u003e\n\nIDLE:\n\n\u003cimg src=\"images/idle.png\" width=\"100%\"\u003e\n\nPowershell:\n\n\u003cimg src=\"images/powershell.png\" width=\"100%\"\u003e\n\n\n\n### Example Code\n```python\n'''\nDeveloped by Abhijith Boppe - linkedin.com/in/abhijith-boppe/\n'''\nfrom clrprint import *\n\nuserclr = clrinput('Enter color: ',clr='green').strip()  # prompt color text\nclrprint('You enterd', userclr,clr=userclr) # print it in that color\n\n# If color not available it print's with default color (white/black)\n\n# Input timeout and clrit (Works on terminal, cmd and powershell. Not supported on IDLE).\ncontinue_ = clrinput('Continue FUZZING? :',clr='p', timeout=15) or False # if no user input in 15, take False\nif continue_:\n  FUZZ()\ncolored_text = clrit('Text1', 'Text2', clr='r,g') # Returns ASCII colored text \nclrhelp()  # to list out usage and available colors.\n```\n\n\u003cbr\u003e\n\u003ca href=\"https://www.buymeacoffee.com/abhijithboppe\" target=\"_blank\"\u003e\u003cimg src=\"https://cdn.buymeacoffee.com/buttons/v2/default-orange.png\" alt=\"Buy Me A Coffee\" width=\"33%\"\u003e\u003c/a\u003e\n\n---\n## License \u0026 copyright\n© Abhijith Boppe, Security analyst\n\n\u003ca href=\"https://linkedin.com/in/abhijith-boppe\" target=\"_blank\"\u003eLinkedIn\u003c/a\u003e\n\n© Dheeraj Kakkar, Software Developer\n\n\u003ca href=\"https://linkedin.com/in/dheerajkakkar\" target=\"_blank\"\u003eLinkedIn\u003c/a\u003e\n\n\nLicensed under the [MIT License](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FAbhijithAJ%2Fclrprint","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FAbhijithAJ%2Fclrprint","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FAbhijithAJ%2Fclrprint/lists"}