{"id":19745730,"url":"https://github.com/dogoncouch/lightcli","last_synced_at":"2025-02-27T23:47:46.856Z","repository":{"id":62576052,"uuid":"85763778","full_name":"dogoncouch/lightcli","owner":"dogoncouch","description":"A Python 3 library module for lightweight terminal interaction.","archived":false,"fork":false,"pushed_at":"2018-04-30T02:49:55.000Z","size":33,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-12T06:53:29.448Z","etag":null,"topics":["cli","cli-utilities","input-method","input-validation","python-3","python-library","python3","python3-library"],"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/dogoncouch.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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":"2017-03-21T23:27:37.000Z","updated_at":"2018-04-30T02:49:57.000Z","dependencies_parsed_at":"2022-11-03T19:03:29.134Z","dependency_job_id":null,"html_url":"https://github.com/dogoncouch/lightcli","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dogoncouch%2Flightcli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dogoncouch%2Flightcli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dogoncouch%2Flightcli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dogoncouch%2Flightcli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dogoncouch","download_url":"https://codeload.github.com/dogoncouch/lightcli/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241077196,"owners_count":19905725,"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","cli-utilities","input-method","input-validation","python-3","python-library","python3","python3-library"],"created_at":"2024-11-12T02:11:05.034Z","updated_at":"2025-02-27T23:47:46.834Z","avatar_url":"https://github.com/dogoncouch.png","language":"Python","readme":"# lightcli\nA Python 3 library module for lightweight terminal interaction\n\n## Index\n- [Installing](#installing)\n- [Introduction](#introduction)\n- [Functions](#functions)\n- [Copyright](#copyright)\n\n## Installing\nSee the latest instructions on the [releases page](https://github.com/dogoncouch/lightcli/releases).\n\n\n# Introdutcion\n\n## Synopsis\n    import lightcli\n    \n    choice = lightcli.choice_input([options=\u003coptions\u003e], [prompt=\u003cprompt\u003e], [showopts={True|False}], [qopt={True|False}])\n    multiline = lightcli.long_input([prompt=\u003cprompt\u003e])\n    mylist = lightcli.list_input([prompt=\u003cprompt\u003e])\n    outputfile = lightcli.outfile_input([extension=\u003cextension\u003e])\n\n## Description\nlightcli is a Python 3 module for lightweight terminal interaction.\n\n\n# Functions\n\n### lightcli.choice\\_input([options=\\\u003coptions\\\u003e], [prompt=\\\u003cprompt\\\u003e], [showopts={True|False}], [qopt={True|False}])\n\nOptions:\n- `` options `` - list of acceptable answers (list of strings)\n- `` prompt `` - text shown when asking for input (a string)\n- `` showopts `` - toggles display of options list (default is True)\n- `` qopt `` - toggles a 'q to quit' option (default is False)\n\nPrompts for and returns input from a list of choices.\n\n### lightcli.long\\_input([prompt=\\\u003cprompt\\\u003e], [maxlines=\\\u003cmaxlines\\\u003e], [maxlength=\\\u003cmaxlength\\\u003e])\n\nOptions:\n- `` prompt `` - text shown when asking for input (a string)\n- `` maxlines `` - sets the maximum number of lines\n- `` maxlength `` - sets the maximum line length\n\nGets a multi-line string as input. Entering an EOF on a blank line ends the input (ctrl-D in \\*nix, ctrl-Z in Windows).\n\n### lightcli.list\\_input([prompt=\\\u003cprompt\\\u003e], [maxitems=\\\u003cmaxitems\\\u003e], [maxlength=\\\u003cmaxlength\\\u003e])\n\nOptions:\n- `` prompt `` - text shown when asking for input (a string)\n- `` maxitems `` - sets the maximum number of items\n- `` maxlength `` - sets the maximum item length\n\nGets a list of strings as input. Each item is entered on a separate line; entering an EOF on a blank line ends the input (ctrl-D in \\*nix, ctrl-Z in Windows).\n\n### lightcli.outfile\\_input([extension=\\\u003cextension\\\u003e])\n\nOptions:\n- `` extension `` - sets the file extension\n\nReturns the name of a writeable output file.\n\n\n# Copyright\nMIT License\n\nCopyright (c) 2017 Dan Persons (dpersonsdev@gmail.com)\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdogoncouch%2Flightcli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdogoncouch%2Flightcli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdogoncouch%2Flightcli/lists"}