ctui


Namectui JSON
Version 0.7.9 PyPI version JSON
download
home_pagehttps://www.controlthings.io
SummaryThe ctui library is similar to Python's built in cmd library, but with a curses-like user interface
upload_time2024-04-20 09:00:55
maintainerNone
docs_urlNone
authorJustin Searle
requires_python<4.0,>=3.8
licenseLGPL
keywords serial fieldbus ics control controlthings
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # ControlThings User Interface

The `ctui` is a library for creating terminal-based user interfaces, and is used in all the ControlThings tools at controlthings.io.  It is similar to using Click or Python's standard Cmd library, but with a curses-like interface written in pure Python.

# Installation

Ctui is primarily developed on Linux, but should work in both Mac and Windows as well.

As long as you have git and Python 3.6 or later installed, all you should need to do is:

```
pip3 install ctui
```

# Usage

Import the library, instantiate a Ctui object, and start the ctui application, like:

```
from ctui import Ctui

myapp = Ctui()
myapp.run()
```

Of course you can configure you app in a number of different ways by modifying your app's attributes or by adding your own custom commands.   Check out the `examples` folder to walk you through some of these.  For more complex examples how to use ctui, check out the various ControlThings Tools, most of which use ctui.  You can find these at <https://github.com/ControlThingsTools>.

# Fork and Develop

To set up a development environment for ctui, you will first need to install [Python Poetry](<https://python-poetry.org>) which is used to manage all the project dependencies and publish the pypi packages.  I strongly recommend checking out the website and at least reading through the [Basic Usage](https://python-poetry.org/docs/basic-usage/) page, but if you want the TLDR, just run:

    curl -sSL https://install.python-poetry.org | python3 -

Once Poetry is installed, pull the repo and :

    git clone https://github.com/ControlThings-io/ctui.git
    cd ctui
    poetry install
    poetry shell

That last command will open a shell in a python virtual environment where you can do live edits to the code.  If you are a VS Code user, VS Code will automatically load the repo configs with all the linting rules I use through the repo, and should automatically open the debug tools and terminal inside the virtual environment.

# Author

* Justin Searle <justin@controlthings.io>

            

Raw data

            {
    "_id": null,
    "home_page": "https://www.controlthings.io",
    "name": "ctui",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.8",
    "maintainer_email": null,
    "keywords": "serial, fieldbus, ICS, control, ControlThings",
    "author": "Justin Searle",
    "author_email": "justin@controlthings.io",
    "download_url": "https://files.pythonhosted.org/packages/d6/b3/ab636ba2cae73924c437b4fe9c9697d0d9ca9179c88cb967e792a6af1231/ctui-0.7.9.tar.gz",
    "platform": null,
    "description": "# ControlThings User Interface\n\nThe `ctui` is a library for creating terminal-based user interfaces, and is used in all the ControlThings tools at controlthings.io.  It is similar to using Click or Python's standard Cmd library, but with a curses-like interface written in pure Python.\n\n# Installation\n\nCtui is primarily developed on Linux, but should work in both Mac and Windows as well.\n\nAs long as you have git and Python 3.6 or later installed, all you should need to do is:\n\n```\npip3 install ctui\n```\n\n# Usage\n\nImport the library, instantiate a Ctui object, and start the ctui application, like:\n\n```\nfrom ctui import Ctui\n\nmyapp = Ctui()\nmyapp.run()\n```\n\nOf course you can configure you app in a number of different ways by modifying your app's attributes or by adding your own custom commands.   Check out the `examples` folder to walk you through some of these.  For more complex examples how to use ctui, check out the various ControlThings Tools, most of which use ctui.  You can find these at <https://github.com/ControlThingsTools>.\n\n# Fork and Develop\n\nTo set up a development environment for ctui, you will first need to install [Python Poetry](<https://python-poetry.org>) which is used to manage all the project dependencies and publish the pypi packages.  I strongly recommend checking out the website and at least reading through the [Basic Usage](https://python-poetry.org/docs/basic-usage/) page, but if you want the TLDR, just run:\n\n    curl -sSL https://install.python-poetry.org | python3 -\n\nOnce Poetry is installed, pull the repo and :\n\n    git clone https://github.com/ControlThings-io/ctui.git\n    cd ctui\n    poetry install\n    poetry shell\n\nThat last command will open a shell in a python virtual environment where you can do live edits to the code.  If you are a VS Code user, VS Code will automatically load the repo configs with all the linting rules I use through the repo, and should automatically open the debug tools and terminal inside the virtual environment.\n\n# Author\n\n* Justin Searle <justin@controlthings.io>\n",
    "bugtrack_url": null,
    "license": "LGPL",
    "summary": "The ctui library is similar to Python's built in cmd library, but with a curses-like user interface",
    "version": "0.7.9",
    "project_urls": {
        "Homepage": "https://www.controlthings.io",
        "Repository": "https://github.com/ControlThings-io/ctserial"
    },
    "split_keywords": [
        "serial",
        " fieldbus",
        " ics",
        " control",
        " controlthings"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "af15628cd7cf5a6fa63d5f93ae927a978dbab770bad0f637a6c2a04d9f7c1dfd",
                "md5": "3ceca73a0906b22e1fc7993f992a0061",
                "sha256": "9ad16682ba8e8cf70d927b42937eb3beb0d13959299a7a2cbdbf35a56c38ed30"
            },
            "downloads": -1,
            "filename": "ctui-0.7.9-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "3ceca73a0906b22e1fc7993f992a0061",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.8",
            "size": 34221,
            "upload_time": "2024-04-20T09:00:53",
            "upload_time_iso_8601": "2024-04-20T09:00:53.831454Z",
            "url": "https://files.pythonhosted.org/packages/af/15/628cd7cf5a6fa63d5f93ae927a978dbab770bad0f637a6c2a04d9f7c1dfd/ctui-0.7.9-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d6b3ab636ba2cae73924c437b4fe9c9697d0d9ca9179c88cb967e792a6af1231",
                "md5": "dd27e03b62d9b6c33c58b06595b86318",
                "sha256": "337f9d6716d9f31b63a63914476498b8ebc48504bd00ff2d90bbfffdbd624622"
            },
            "downloads": -1,
            "filename": "ctui-0.7.9.tar.gz",
            "has_sig": false,
            "md5_digest": "dd27e03b62d9b6c33c58b06595b86318",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.8",
            "size": 28441,
            "upload_time": "2024-04-20T09:00:55",
            "upload_time_iso_8601": "2024-04-20T09:00:55.955483Z",
            "url": "https://files.pythonhosted.org/packages/d6/b3/ab636ba2cae73924c437b4fe9c9697d0d9ca9179c88cb967e792a6af1231/ctui-0.7.9.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-04-20 09:00:55",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "ControlThings-io",
    "github_project": "ctserial",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "ctui"
}
        
Elapsed time: 0.26793s