git-monitor


Namegit-monitor JSON
Version 0.1.6 PyPI version JSON
download
home_pagehttps://github.com/baliuzeger/py_git_monitor
SummaryAutomatic print the git status of the package your are developing.
upload_time2024-08-20 02:47:42
maintainerNone
docs_urlNone
authorbali
requires_python<4.0,>=3.11
licenseNone
keywords git log datascience
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Use Case

This project is intended to improve datascience workflows. You may want to do these simultaneously:
1. Developing a package (the *package project*), possibly a machine learning model or a data pipeline.
2. Perform some experiments in another project (the *experiment project*) by such *package project* by running a jupyter notebook or a script.
3. Log the git status of the *package project* for reproducibiliy.

`git-monitor` help you to conviniently log the git status.

If we don't want the notebooks to polute the *package project*, we have to separate the *experiment project* from the *package project*, then we cannot track everying directly in a single git repo. This problem is what `git-monitor` built for.

# How to

## Basic usage

1. Install `git-monitor` into the environment of your *package project*.
2. Make a `.git_monitor` file in the *experiment project*:
```
<pkg-nm-1>=<path-to-package-1-project-root>
<pkg-nm-2>=<path-to-package-2-project-root>
```
3. In the root `__init__.py` of the *package project*, add the lines:
```python
import git_monitor
git_monitor.Monitor.by_env("<pkg-nm-1>")
```

Then everytime you `import` or `reload` the *package project* under the *experiment project*, `git-monitor` will print the git status, including current branch, commit hash, untracked files and modified files.

## logger
```python
from git_monitor import logger
```
the messages of `git-monitor` are directed to this `logger`, which is a python native `logging.Logger` and an `logging.StreamHandler` has already been added to. The logging level is `INFO`, and the `StreamHandler` uses `sys.stdout`.
            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/baliuzeger/py_git_monitor",
    "name": "git-monitor",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.11",
    "maintainer_email": null,
    "keywords": "git, log, datascience",
    "author": "bali",
    "author_email": "baliuzeger@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/45/ae/0a272f2570987da5b467dd2895146f9a4c61fc40b1f5012a9c32d3946b5a/git_monitor-0.1.6.tar.gz",
    "platform": null,
    "description": "# Use Case\n\nThis project is intended to improve datascience workflows. You may want to do these simultaneously:\n1. Developing a package (the *package project*), possibly a machine learning model or a data pipeline.\n2. Perform some experiments in another project (the *experiment project*) by such *package project* by running a jupyter notebook or a script.\n3. Log the git status of the *package project* for reproducibiliy.\n\n`git-monitor` help you to conviniently log the git status.\n\nIf we don't want the notebooks to polute the *package project*, we have to separate the *experiment project* from the *package project*, then we cannot track everying directly in a single git repo. This problem is what `git-monitor` built for.\n\n# How to\n\n## Basic usage\n\n1. Install `git-monitor` into the environment of your *package project*.\n2. Make a `.git_monitor` file in the *experiment project*:\n```\n<pkg-nm-1>=<path-to-package-1-project-root>\n<pkg-nm-2>=<path-to-package-2-project-root>\n```\n3. In the root `__init__.py` of the *package project*, add the lines:\n```python\nimport git_monitor\ngit_monitor.Monitor.by_env(\"<pkg-nm-1>\")\n```\n\nThen everytime you `import` or `reload` the *package project* under the *experiment project*, `git-monitor` will print the git status, including current branch, commit hash, untracked files and modified files.\n\n## logger\n```python\nfrom git_monitor import logger\n```\nthe messages of `git-monitor` are directed to this `logger`, which is a python native `logging.Logger` and an `logging.StreamHandler` has already been added to. The logging level is `INFO`, and the `StreamHandler` uses `sys.stdout`.",
    "bugtrack_url": null,
    "license": null,
    "summary": "Automatic print the git status of the package your are developing.",
    "version": "0.1.6",
    "project_urls": {
        "Homepage": "https://github.com/baliuzeger/py_git_monitor",
        "Repository": "https://github.com/baliuzeger/py_git_monitor"
    },
    "split_keywords": [
        "git",
        " log",
        " datascience"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d6843fb0c8208168c70a2900d16d8293b013fae17999a908551eaebac4c758dc",
                "md5": "32f4f86f87580c0ae056729ace657c52",
                "sha256": "45a10393bb6e7340cece49ea1c62e43305449366e2b52ce066f254cfc1541b09"
            },
            "downloads": -1,
            "filename": "git_monitor-0.1.6-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "32f4f86f87580c0ae056729ace657c52",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.11",
            "size": 7063,
            "upload_time": "2024-08-20T02:47:41",
            "upload_time_iso_8601": "2024-08-20T02:47:41.637971Z",
            "url": "https://files.pythonhosted.org/packages/d6/84/3fb0c8208168c70a2900d16d8293b013fae17999a908551eaebac4c758dc/git_monitor-0.1.6-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "45ae0a272f2570987da5b467dd2895146f9a4c61fc40b1f5012a9c32d3946b5a",
                "md5": "e77d88c10f1b7c01d52e2f408f271d88",
                "sha256": "1feb1e6a7feef191168e94f3129976660eddf445e9c2ab9fb281c82e805524c5"
            },
            "downloads": -1,
            "filename": "git_monitor-0.1.6.tar.gz",
            "has_sig": false,
            "md5_digest": "e77d88c10f1b7c01d52e2f408f271d88",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.11",
            "size": 6232,
            "upload_time": "2024-08-20T02:47:42",
            "upload_time_iso_8601": "2024-08-20T02:47:42.990482Z",
            "url": "https://files.pythonhosted.org/packages/45/ae/0a272f2570987da5b467dd2895146f9a4c61fc40b1f5012a9c32d3946b5a/git_monitor-0.1.6.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-08-20 02:47:42",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "baliuzeger",
    "github_project": "py_git_monitor",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "git-monitor"
}
        
Elapsed time: 3.54896s