app-skellington


Nameapp-skellington JSON
Version 0.2.2 PyPI version JSON
download
home_pageNone
Summaryapp_skellington CLI framework
upload_time2024-11-17 06:33:35
maintainerNone
docs_urlNone
authorNone
requires_python>=3.8
licenseApp Skellington MIT No Attribution Copyright (c) 2024 Mathew Guest Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN `NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
keywords cli logging application
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            app_skellington
===============

Application framework for Python, features include:
 - Pain-free multi-level command menu: Expose public class methods as commands available to user.
 - Simple to define services and automatic dependency injection based on name (with custom invocation as an option). \*WIP
 - INI-style config and and validation (provided through ConfigObj).
 - Colored logging (provided through colorlog)
 - Works on Linux, Windows, and Mac.

Principles:
 - Lend to creating beautiful, easy to read and understand code in the application.
 - Minimize coupling of applications to this framework.
 - Compatible with Linux, Windows, and Mac. Try to be compatible as possible otherwise.
 - Try to be compatible with alternate Python runtimes such as PyPy and older python environments. \*WIP

# PyPi Hosted Link

https://pypi.org/project/app-skellington/

# Application Configuration

Site configurations are supported through ConfigObj. There is a config.spec
in the src directory which is a validation file; it contains the accepted
parameter names, types, and limits for configurable options in the
application which is built on app_skellington. The format is multi-level .ini syntax.

Reference the ConfigObj documentation for config.ini and config.spec
format. See:

 - https://configobj.readthedocs.io/en/latest/configobj.html#the-config-file-format
 - https://configobj.readthedocs.io/en/latest/configobj.html#validation

Config files (config.ini) are created if they don't exist. The
file always contains the full specification of parameters; i.e. even default
parameters are added into the config file.

Linux:

 * /home/\<user\>/.config/\<app_name\>/config.ini
 * /home/\<user\>/.cache/\<app_name\>/log/\<app_name\>.log

Windows:

 * C:\\Users\\\<user>\\\<app_name\>\\Local\\\<app_name\>\\config.ini
 * C:\\Users\\\<user>\\\<app_name\>\\Local\\\<app_name\>\\Logs\\\<app_name\>.log

Application configuration can be overridden ad-hoc through the --config <filename>
argument.

# Debug - Turn on Logging

Set 'APPSKELLINGTON_ENABLE_LOGGING' environment variable to any value which turns
on AppSkellington-level logging. For example,

    APPSKELLINGTON_DEBUG=1 <executable>

or

    export APPSKELLINGTON_DEBUG=1
    <executable>

# Tests

Tests are a WIP. Recommendation is to run 'pytest' in the 'tests' directory.

# Development

I recommend pyenv to install a reliable, controlled python of preferred version locally.

```
curl https://pyenv.run | bash

# Add to .bashrc or similar for different shells:
tee -a "$HOME"/.profile <<'EOF'

export PYENV_ROOT="$HOME/.pyenv"
[[ -d $PYENV_ROOT/bin ]] && export PATH="$PYENV_ROOT/bin:$PATH"
eval "$(pyenv init -)"

EOF
```
 * reference https://github.com/pyenv/pyenv
 * Use pyenv to install desired python version, and/or create any virtual environments you desire

Clone the repo:
```commandline
git clone https://git-repos.zavage.net/zavage-software/app_skellington.git
```

Install pre-commit hooks:
```commandline
pre-commit install
```

Build:
```
python -m build
```

Install:

```
pip install .
```

Formatting and Linters:
```
black app_skellington
isort app_skellington
flake8 app_skellington
```

Publish:

```
# Push latest commit, or on commit ready to publish:
git push

# Create a tag with the desired version number and push:
git tag -a v0.2.0 -m "0.2.0 provides modern pyproject.toml build with setuptools, versioning, and publishing"
git push origin v0.2.0

# Build the wheel:
python -m build

# Publish to pypi:
twine check dist/*
twine upload dist/*
```
 * Reference https://packaging.python.org/en/latest/overview/


# Version

setuptools_scm will infer the version based on the latest tag in your Git history.
Ensure you are tagging your commits with meaningful version numbers like v1.0.0, v1.1.0, etc.

You can view the current version number with the command:

    python -m setuptools_scm

# License

MIT no attribution required - https://opensource.org/license/mit-0

 * Allows commercial use.
 * Allows modifications and closed-source derivatives.
 * Fully interoperable with nearly all other open-source licenses, including GPL (when combined properly).

# See Also

 * Project page: https://zavage-software.com/portfolio/app_skellington
 * Please report bugs, improvements, or feedback!
 * Contact: mat@zavage.net

 * Packing and distribution conforms to PEP 621 https://peps.python.org/pep-0621/
 * Reference https://packaging.python.org/en/latest/guides/distributing-packages-using-setuptools/

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "app-skellington",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "cli, logging, application",
    "author": null,
    "author_email": "Mathew Guest <mat@zavage.net>",
    "download_url": "https://files.pythonhosted.org/packages/0c/b0/70646bbba2c08c54bf40a7e2eb1c88025d8dfd31bc2ad23c88dc691c85a4/app_skellington-0.2.2.tar.gz",
    "platform": null,
    "description": "app_skellington\n===============\n\nApplication framework for Python, features include:\n - Pain-free multi-level command menu: Expose public class methods as commands available to user.\n - Simple to define services and automatic dependency injection based on name (with custom invocation as an option). \\*WIP\n - INI-style config and and validation (provided through ConfigObj).\n - Colored logging (provided through colorlog)\n - Works on Linux, Windows, and Mac.\n\nPrinciples:\n - Lend to creating beautiful, easy to read and understand code in the application.\n - Minimize coupling of applications to this framework.\n - Compatible with Linux, Windows, and Mac. Try to be compatible as possible otherwise.\n - Try to be compatible with alternate Python runtimes such as PyPy and older python environments. \\*WIP\n\n# PyPi Hosted Link\n\nhttps://pypi.org/project/app-skellington/\n\n# Application Configuration\n\nSite configurations are supported through ConfigObj. There is a config.spec\nin the src directory which is a validation file; it contains the accepted\nparameter names, types, and limits for configurable options in the\napplication which is built on app_skellington. The format is multi-level .ini syntax.\n\nReference the ConfigObj documentation for config.ini and config.spec\nformat. See:\n\n - https://configobj.readthedocs.io/en/latest/configobj.html#the-config-file-format\n - https://configobj.readthedocs.io/en/latest/configobj.html#validation\n\nConfig files (config.ini) are created if they don't exist. The\nfile always contains the full specification of parameters; i.e. even default\nparameters are added into the config file.\n\nLinux:\n\n * /home/\\<user\\>/.config/\\<app_name\\>/config.ini\n * /home/\\<user\\>/.cache/\\<app_name\\>/log/\\<app_name\\>.log\n\nWindows:\n\n * C:\\\\Users\\\\\\<user>\\\\\\<app_name\\>\\\\Local\\\\\\<app_name\\>\\\\config.ini\n * C:\\\\Users\\\\\\<user>\\\\\\<app_name\\>\\\\Local\\\\\\<app_name\\>\\\\Logs\\\\\\<app_name\\>.log\n\nApplication configuration can be overridden ad-hoc through the --config <filename>\nargument.\n\n# Debug - Turn on Logging\n\nSet 'APPSKELLINGTON_ENABLE_LOGGING' environment variable to any value which turns\non AppSkellington-level logging. For example,\n\n    APPSKELLINGTON_DEBUG=1 <executable>\n\nor\n\n    export APPSKELLINGTON_DEBUG=1\n    <executable>\n\n# Tests\n\nTests are a WIP. Recommendation is to run 'pytest' in the 'tests' directory.\n\n# Development\n\nI recommend pyenv to install a reliable, controlled python of preferred version locally.\n\n```\ncurl https://pyenv.run | bash\n\n# Add to .bashrc or similar for different shells:\ntee -a \"$HOME\"/.profile <<'EOF'\n\nexport PYENV_ROOT=\"$HOME/.pyenv\"\n[[ -d $PYENV_ROOT/bin ]] && export PATH=\"$PYENV_ROOT/bin:$PATH\"\neval \"$(pyenv init -)\"\n\nEOF\n```\n * reference https://github.com/pyenv/pyenv\n * Use pyenv to install desired python version, and/or create any virtual environments you desire\n\nClone the repo:\n```commandline\ngit clone https://git-repos.zavage.net/zavage-software/app_skellington.git\n```\n\nInstall pre-commit hooks:\n```commandline\npre-commit install\n```\n\nBuild:\n```\npython -m build\n```\n\nInstall:\n\n```\npip install .\n```\n\nFormatting and Linters:\n```\nblack app_skellington\nisort app_skellington\nflake8 app_skellington\n```\n\nPublish:\n\n```\n# Push latest commit, or on commit ready to publish:\ngit push\n\n# Create a tag with the desired version number and push:\ngit tag -a v0.2.0 -m \"0.2.0 provides modern pyproject.toml build with setuptools, versioning, and publishing\"\ngit push origin v0.2.0\n\n# Build the wheel:\npython -m build\n\n# Publish to pypi:\ntwine check dist/*\ntwine upload dist/*\n```\n * Reference https://packaging.python.org/en/latest/overview/\n\n\n# Version\n\nsetuptools_scm will infer the version based on the latest tag in your Git history.\nEnsure you are tagging your commits with meaningful version numbers like v1.0.0, v1.1.0, etc.\n\nYou can view the current version number with the command:\n\n    python -m setuptools_scm\n\n# License\n\nMIT no attribution required - https://opensource.org/license/mit-0\n\n * Allows commercial use.\n * Allows modifications and closed-source derivatives.\n * Fully interoperable with nearly all other open-source licenses, including GPL (when combined properly).\n\n# See Also\n\n * Project page: https://zavage-software.com/portfolio/app_skellington\n * Please report bugs, improvements, or feedback!\n * Contact: mat@zavage.net\n\n * Packing and distribution conforms to PEP 621 https://peps.python.org/pep-0621/\n * Reference https://packaging.python.org/en/latest/guides/distributing-packages-using-setuptools/\n",
    "bugtrack_url": null,
    "license": "App Skellington  MIT No Attribution  Copyright (c) 2024 Mathew Guest  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so.  THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN `NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ",
    "summary": "app_skellington CLI framework",
    "version": "0.2.2",
    "project_urls": {
        "documentation": "https://git-repos.zavage.net/Zavage-Software/app_skellington",
        "homepage": "https://zavage-software.com/portfolio/app_skellington",
        "repository": "https://git-repos.zavage.net/Zavage-Software/app_skellington"
    },
    "split_keywords": [
        "cli",
        " logging",
        " application"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "dd68a99346938eff296c3cd44795f9f20d7fc31d9af50bebdb9e4f43cf64319b",
                "md5": "ad77162645339b257a39bf310560844a",
                "sha256": "7c330c2c60a19012132f0d2bab6676c7a35648f0b6d87ff602e24965c1628dd5"
            },
            "downloads": -1,
            "filename": "app_skellington-0.2.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "ad77162645339b257a39bf310560844a",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 20846,
            "upload_time": "2024-11-17T06:33:34",
            "upload_time_iso_8601": "2024-11-17T06:33:34.262566Z",
            "url": "https://files.pythonhosted.org/packages/dd/68/a99346938eff296c3cd44795f9f20d7fc31d9af50bebdb9e4f43cf64319b/app_skellington-0.2.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "0cb070646bbba2c08c54bf40a7e2eb1c88025d8dfd31bc2ad23c88dc691c85a4",
                "md5": "6a77bda0bd2748a2c81a54ffaf2e9f1e",
                "sha256": "05d735e7625124a9f2790b278abe55f2d21502e7c5d03201fbb1e277f067711f"
            },
            "downloads": -1,
            "filename": "app_skellington-0.2.2.tar.gz",
            "has_sig": false,
            "md5_digest": "6a77bda0bd2748a2c81a54ffaf2e9f1e",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 22314,
            "upload_time": "2024-11-17T06:33:35",
            "upload_time_iso_8601": "2024-11-17T06:33:35.445695Z",
            "url": "https://files.pythonhosted.org/packages/0c/b0/70646bbba2c08c54bf40a7e2eb1c88025d8dfd31bc2ad23c88dc691c85a4/app_skellington-0.2.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-11-17 06:33:35",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "app-skellington"
}
        
Elapsed time: 0.40569s