## Consoler
A terminal printer that's totally tailored to how I like terminal printouts. If this happens to also be how you like terminal printouts, this package may well be for you too.
### Installing
`poetry add consoler` or `pip install consoler`
### Usage
from consoler import console
console.log("This is a log level print out")
console.info("This is an info level print out")
console.warn("This is a warning level print out")
try:
1 / 0
except Exception as e:
console.error("Oh no!", e)
### Settings
Using with Django you set a few things in the Django settings to affect behaviour of conoler.
DEBUG = True
If `DEBUG` is `True` consoler will print to stdout, otherwise it will send the output to loguru.
CONSOLE_LOG_LEVEL = 'LOG'
You can set a log level for which message you want to reach the screen. Available levels are...
LOG
INFO
SUCCESS
TEMPLATE
WARN
ERROR
CONSOLE_PATH_PREFIX = ''
When developing in a docker container or VM, the start of consoler's file paths might not quite match your local filesystem. Set a prefix here to prepend to the output's path string. This is super useful if you use https://github.com/dandavison/iterm2-dwim to make file paths clickable in iTerm.
### Changelog
#### 0.1.5
* Remove the hard dependency on loguru, it still works with it, but this way we don't need to keep this package up to date with loguru releases.
* Slightly modernise the code a little.
Raw data
{
"_id": null,
"home_page": "https://github.com/hactar-is/consoler",
"name": "consoler",
"maintainer": null,
"docs_url": null,
"requires_python": "<4.0,>=3.6",
"maintainer_email": null,
"keywords": "console, terminal, logging",
"author": "Hactar",
"author_email": "systems@hactar.is",
"download_url": "https://files.pythonhosted.org/packages/7c/6a/5df3be755bbe1bb2e8f7c50e862344da17649925909fec714b324e5729b1/consoler-0.1.7.tar.gz",
"platform": null,
"description": "## Consoler\n\nA terminal printer that's totally tailored to how I like terminal printouts. If this happens to also be how you like terminal printouts, this package may well be for you too.\n\n### Installing\n\n`poetry add consoler` or `pip install consoler`\n\n### Usage\n\n from consoler import console\n console.log(\"This is a log level print out\")\n console.info(\"This is an info level print out\")\n console.warn(\"This is a warning level print out\")\n\n try:\n 1 / 0\n except Exception as e:\n console.error(\"Oh no!\", e)\n\n\n### Settings\n\nUsing with Django you set a few things in the Django settings to affect behaviour of conoler.\n\n DEBUG = True\n\nIf `DEBUG` is `True` consoler will print to stdout, otherwise it will send the output to loguru.\n\n CONSOLE_LOG_LEVEL = 'LOG'\n\nYou can set a log level for which message you want to reach the screen. Available levels are...\n\n LOG\n INFO\n SUCCESS\n TEMPLATE\n WARN\n ERROR\n\n CONSOLE_PATH_PREFIX = ''\n\nWhen developing in a docker container or VM, the start of consoler's file paths might not quite match your local filesystem. Set a prefix here to prepend to the output's path string. This is super useful if you use https://github.com/dandavison/iterm2-dwim to make file paths clickable in iTerm.\n\n\n### Changelog\n\n#### 0.1.5\n* Remove the hard dependency on loguru, it still works with it, but this way we don't need to keep this package up to date with loguru releases.\n* Slightly modernise the code a little.\n",
"bugtrack_url": null,
"license": "MIT",
"summary": null,
"version": "0.1.7",
"project_urls": {
"Homepage": "https://github.com/hactar-is/consoler",
"Repository": "https://github.com/hactar-is/consoler"
},
"split_keywords": [
"console",
" terminal",
" logging"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "c912d3e248c38851c4f06011978258d82ead34bbe903ba21809b32f09dd5aa13",
"md5": "f7815e9ee02a0c1ffffd23d880d1175a",
"sha256": "3efcd1ee2de2d03724654b5856d1c8a5d74e3657f548dd3fda4b7335b63a9f2f"
},
"downloads": -1,
"filename": "consoler-0.1.7-py3-none-any.whl",
"has_sig": false,
"md5_digest": "f7815e9ee02a0c1ffffd23d880d1175a",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<4.0,>=3.6",
"size": 6795,
"upload_time": "2024-04-10T12:37:27",
"upload_time_iso_8601": "2024-04-10T12:37:27.387745Z",
"url": "https://files.pythonhosted.org/packages/c9/12/d3e248c38851c4f06011978258d82ead34bbe903ba21809b32f09dd5aa13/consoler-0.1.7-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "7c6a5df3be755bbe1bb2e8f7c50e862344da17649925909fec714b324e5729b1",
"md5": "92cad05c4c68f08b9e778e5e4d5e4bca",
"sha256": "93e8859af775e082ea696bc43aac5d6a607a3aa1955b4e188fafa425970228bf"
},
"downloads": -1,
"filename": "consoler-0.1.7.tar.gz",
"has_sig": false,
"md5_digest": "92cad05c4c68f08b9e778e5e4d5e4bca",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "<4.0,>=3.6",
"size": 5269,
"upload_time": "2024-04-10T12:37:28",
"upload_time_iso_8601": "2024-04-10T12:37:28.471710Z",
"url": "https://files.pythonhosted.org/packages/7c/6a/5df3be755bbe1bb2e8f7c50e862344da17649925909fec714b324e5729b1/consoler-0.1.7.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-04-10 12:37:28",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "hactar-is",
"github_project": "consoler",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "consoler"
}