coollog


Namecoollog JSON
Version 0.1.3 PyPI version JSON
download
home_pageNone
SummaryA simple and colorful logger for Python
upload_time2025-08-27 10:25:14
maintainerNone
docs_urlNone
authorNone
requires_pythonNone
licenseMIT
keywords logger color console python
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # CoolLog


## ✨ ویژگی‌ها
- نمایش لاگ‌ها در ترمینال با رنگ‌بندی متفاوت برای هر سطح
- ذخیره لاگ‌ها در فایل `logs.txt`
- شامل سطوح:
  - `ERROR`
  - `WARNING`
  - `SUCCESS`
  - `INFO`
  - `DEBUG`
  - `CRITICAL`

---

## 📦 نصب
```bash
pip install coollog
````
---

## 📖 مثال استفاده

```python
from coollog import CoolLog

CoolLog.error("این یک خطای تستی است")
CoolLog.warning("این یک هشدار است")
CoolLog.success("عملیات با موفقیت انجام شد")
CoolLog.info("اطلاعات سیستمی ثبت شد")
CoolLog.debug("دیباگ کردن مرحله‌ی 1")
CoolLog.critical("خطای بحرانی در سیستم")
```

---
## auto log
میتونی فایل رو از طریق این قابلیت ران کنی و برنامه به صورت هوشمند برای تو لاگ بگیره
مثال: 
```python
from coollog import CoolLog

log = CoolLog()

log.auto_log("a.py")

```
---
## 📂 خروجی در ترمینال
مثال (با رنگ‌بندی واقعی در ترمینال قابل مشاهده است):

```
[ERROR-2025-08-27 12:30:15]  این یک خطای تستی است
[WARNING-2025-08-27 12:30:15]  این یک هشدار است
[SUCCESS-2025-08-27 12:30:15]  عملیات با موفقیت انجام شد
```

---

## 📝 ذخیره در فایل
تمامی لاگ‌ها علاوه بر نمایش در ترمینال، در فایل `logs.txt` نیز ذخیره می‌شوند:

```
[ERROR-2025-08-27 12:30:15] این یک خطای تستی است
[WARNING-2025-08-27 12:30:15] این یک هشدار است
```

---

## 📜 لایسنس
این پروژه آزاد است و می‌توانید بدون محدودیت از آن استفاده کنید.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "coollog",
    "maintainer": null,
    "docs_url": null,
    "requires_python": null,
    "maintainer_email": null,
    "keywords": "logger, color, console, python",
    "author": null,
    "author_email": "Mohammad Reza Hosein Nia <id.suzuya@email.com>",
    "download_url": "https://files.pythonhosted.org/packages/cd/c9/79b95e081f42257e6570f0f1357cc6ffb22c546e1c03ce36e5fef94d4f46/coollog-0.1.3.tar.gz",
    "platform": null,
    "description": "# CoolLog\r\n\r\n\r\n## \u2728 \u0648\u06cc\u0698\u06af\u06cc\u200c\u0647\u0627\r\n- \u0646\u0645\u0627\u06cc\u0634 \u0644\u0627\u06af\u200c\u0647\u0627 \u062f\u0631 \u062a\u0631\u0645\u06cc\u0646\u0627\u0644 \u0628\u0627 \u0631\u0646\u06af\u200c\u0628\u0646\u062f\u06cc \u0645\u062a\u0641\u0627\u0648\u062a \u0628\u0631\u0627\u06cc \u0647\u0631 \u0633\u0637\u062d\r\n- \u0630\u062e\u06cc\u0631\u0647 \u0644\u0627\u06af\u200c\u0647\u0627 \u062f\u0631 \u0641\u0627\u06cc\u0644 `logs.txt`\r\n- \u0634\u0627\u0645\u0644 \u0633\u0637\u0648\u062d:\r\n  - `ERROR`\r\n  - `WARNING`\r\n  - `SUCCESS`\r\n  - `INFO`\r\n  - `DEBUG`\r\n  - `CRITICAL`\r\n\r\n---\r\n\r\n## \ud83d\udce6 \u0646\u0635\u0628\r\n```bash\r\npip install coollog\r\n````\r\n---\r\n\r\n## \ud83d\udcd6 \u0645\u062b\u0627\u0644 \u0627\u0633\u062a\u0641\u0627\u062f\u0647\r\n\r\n```python\r\nfrom coollog import CoolLog\r\n\r\nCoolLog.error(\"\u0627\u06cc\u0646 \u06cc\u06a9 \u062e\u0637\u0627\u06cc \u062a\u0633\u062a\u06cc \u0627\u0633\u062a\")\r\nCoolLog.warning(\"\u0627\u06cc\u0646 \u06cc\u06a9 \u0647\u0634\u062f\u0627\u0631 \u0627\u0633\u062a\")\r\nCoolLog.success(\"\u0639\u0645\u0644\u06cc\u0627\u062a \u0628\u0627 \u0645\u0648\u0641\u0642\u06cc\u062a \u0627\u0646\u062c\u0627\u0645 \u0634\u062f\")\r\nCoolLog.info(\"\u0627\u0637\u0644\u0627\u0639\u0627\u062a \u0633\u06cc\u0633\u062a\u0645\u06cc \u062b\u0628\u062a \u0634\u062f\")\r\nCoolLog.debug(\"\u062f\u06cc\u0628\u0627\u06af \u06a9\u0631\u062f\u0646 \u0645\u0631\u062d\u0644\u0647\u200c\u06cc 1\")\r\nCoolLog.critical(\"\u062e\u0637\u0627\u06cc \u0628\u062d\u0631\u0627\u0646\u06cc \u062f\u0631 \u0633\u06cc\u0633\u062a\u0645\")\r\n```\r\n\r\n---\r\n## auto log\r\n\u0645\u06cc\u062a\u0648\u0646\u06cc \u0641\u0627\u06cc\u0644 \u0631\u0648 \u0627\u0632 \u0637\u0631\u06cc\u0642 \u0627\u06cc\u0646 \u0642\u0627\u0628\u0644\u06cc\u062a \u0631\u0627\u0646 \u06a9\u0646\u06cc \u0648 \u0628\u0631\u0646\u0627\u0645\u0647 \u0628\u0647 \u0635\u0648\u0631\u062a \u0647\u0648\u0634\u0645\u0646\u062f \u0628\u0631\u0627\u06cc \u062a\u0648 \u0644\u0627\u06af \u0628\u06af\u06cc\u0631\u0647\r\n\u0645\u062b\u0627\u0644: \r\n```python\r\nfrom coollog import CoolLog\r\n\r\nlog = CoolLog()\r\n\r\nlog.auto_log(\"a.py\")\r\n\r\n```\r\n---\r\n## \ud83d\udcc2 \u062e\u0631\u0648\u062c\u06cc \u062f\u0631 \u062a\u0631\u0645\u06cc\u0646\u0627\u0644\r\n\u0645\u062b\u0627\u0644 (\u0628\u0627 \u0631\u0646\u06af\u200c\u0628\u0646\u062f\u06cc \u0648\u0627\u0642\u0639\u06cc \u062f\u0631 \u062a\u0631\u0645\u06cc\u0646\u0627\u0644 \u0642\u0627\u0628\u0644 \u0645\u0634\u0627\u0647\u062f\u0647 \u0627\u0633\u062a):\r\n\r\n```\r\n[ERROR-2025-08-27 12:30:15]  \u0627\u06cc\u0646 \u06cc\u06a9 \u062e\u0637\u0627\u06cc \u062a\u0633\u062a\u06cc \u0627\u0633\u062a\r\n[WARNING-2025-08-27 12:30:15]  \u0627\u06cc\u0646 \u06cc\u06a9 \u0647\u0634\u062f\u0627\u0631 \u0627\u0633\u062a\r\n[SUCCESS-2025-08-27 12:30:15]  \u0639\u0645\u0644\u06cc\u0627\u062a \u0628\u0627 \u0645\u0648\u0641\u0642\u06cc\u062a \u0627\u0646\u062c\u0627\u0645 \u0634\u062f\r\n```\r\n\r\n---\r\n\r\n## \ud83d\udcdd \u0630\u062e\u06cc\u0631\u0647 \u062f\u0631 \u0641\u0627\u06cc\u0644\r\n\u062a\u0645\u0627\u0645\u06cc \u0644\u0627\u06af\u200c\u0647\u0627 \u0639\u0644\u0627\u0648\u0647 \u0628\u0631 \u0646\u0645\u0627\u06cc\u0634 \u062f\u0631 \u062a\u0631\u0645\u06cc\u0646\u0627\u0644\u060c \u062f\u0631 \u0641\u0627\u06cc\u0644 `logs.txt` \u0646\u06cc\u0632 \u0630\u062e\u06cc\u0631\u0647 \u0645\u06cc\u200c\u0634\u0648\u0646\u062f:\r\n\r\n```\r\n[ERROR-2025-08-27 12:30:15] \u0627\u06cc\u0646 \u06cc\u06a9 \u062e\u0637\u0627\u06cc \u062a\u0633\u062a\u06cc \u0627\u0633\u062a\r\n[WARNING-2025-08-27 12:30:15] \u0627\u06cc\u0646 \u06cc\u06a9 \u0647\u0634\u062f\u0627\u0631 \u0627\u0633\u062a\r\n```\r\n\r\n---\r\n\r\n## \ud83d\udcdc \u0644\u0627\u06cc\u0633\u0646\u0633\r\n\u0627\u06cc\u0646 \u067e\u0631\u0648\u0698\u0647 \u0622\u0632\u0627\u062f \u0627\u0633\u062a \u0648 \u0645\u06cc\u200c\u062a\u0648\u0627\u0646\u06cc\u062f \u0628\u062f\u0648\u0646 \u0645\u062d\u062f\u0648\u062f\u06cc\u062a \u0627\u0632 \u0622\u0646 \u0627\u0633\u062a\u0641\u0627\u062f\u0647 \u06a9\u0646\u06cc\u062f.\r\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "A simple and colorful logger for Python",
    "version": "0.1.3",
    "project_urls": {
        "Bug Tracker": "https://github.com/mmd-dll/coollog/issues",
        "Homepage": "https://github.com/mmd-dll/coollog"
    },
    "split_keywords": [
        "logger",
        " color",
        " console",
        " python"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "4ecc9152bc68da0fda4760e0463df4a77f8c6c59353bee359cc4a10130661aaf",
                "md5": "2c21aa47c6bd911955eb258562ac0ce4",
                "sha256": "b02688b223ba31722a5785f4221597f8b4280952bef9bca75925272988288268"
            },
            "downloads": -1,
            "filename": "coollog-0.1.3-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "2c21aa47c6bd911955eb258562ac0ce4",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 3328,
            "upload_time": "2025-08-27T10:25:13",
            "upload_time_iso_8601": "2025-08-27T10:25:13.037061Z",
            "url": "https://files.pythonhosted.org/packages/4e/cc/9152bc68da0fda4760e0463df4a77f8c6c59353bee359cc4a10130661aaf/coollog-0.1.3-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "cdc979b95e081f42257e6570f0f1357cc6ffb22c546e1c03ce36e5fef94d4f46",
                "md5": "4574353386d596f0600f878d1cde02a1",
                "sha256": "c643d44ce42b02abc772f34bf850745e750bc2baf2254d4d7a43651218b913f9"
            },
            "downloads": -1,
            "filename": "coollog-0.1.3.tar.gz",
            "has_sig": false,
            "md5_digest": "4574353386d596f0600f878d1cde02a1",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 3105,
            "upload_time": "2025-08-27T10:25:14",
            "upload_time_iso_8601": "2025-08-27T10:25:14.409464Z",
            "url": "https://files.pythonhosted.org/packages/cd/c9/79b95e081f42257e6570f0f1357cc6ffb22c546e1c03ce36e5fef94d4f46/coollog-0.1.3.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-08-27 10:25:14",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "mmd-dll",
    "github_project": "coollog",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "coollog"
}
        
Elapsed time: 0.84119s