{ "info": { "author": "Jan Petykiewicz", "author_email": "anewusername@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Environment :: Other Environment", "Intended Audience :: Developers", "Intended Audience :: Science/Research", "License :: OSI Approved :: GNU General Public License v3 (GPLv3)", "Programming Language :: Python", "Programming Language :: Python :: 3", "Topic :: Software Development :: Version Control :: Git", "Topic :: Utilities" ], "description": "# lethe README\n\n```lethe``` is a Python module for git-based snapshotting.\n\n```lethe``` is intended as a mechanism for creating commits outside \nthe standard git branching/tagging workflows. It is meant to enable\nadditional use-cases without disrupting the standard workflows.\nUse cases include:\n\n- Short-lived:\n - On-disk **undo log**\n - **Syncing work-in-progress** between computers before it's ready \n- Long-lived:\n - **lab notebook**: Recording the code / configuration state that resulted in a given output\n - **incremental backup**: Space-efficient time-based backups of a codebase \n\n\n## Usage\n\n### Creating a commit from the command line \n```bash\n$ cd path/to/repo\n$ lethe\n122d058e375274a186c407f28602c3b14a2cab95\n```\nThis effectively snapshots the current state of the repository (as would be seen by\n```git add --all```) and creates a new commit (```122d058e375274a186c407f28602c3b14a2cab95```)\nwhich points to it. The current branch and index are not changed.\n\n### Flags:\n- ```-p my_parent_ref``` is used to provide \"parent\" refs which become the parents of the created commit.\nIf a parent ref is a symbolic ref, *both* the provided ref and the ref it points to are used as parents.\nIf not present, defaults to ```-p HEAD```.\n- ```-t ref/lethe/my_target_ref``` is used to provide \"target\" refs which will be created/updated\nto point to the created commit.\nIf not present, defaults to adding an entry of the form ```-t refs/lethe/my_branch``` for each\nparent ref of the form ```refs/heads/my_branch```, and ```-t refs/lethe/my/refpath``` for non-head\nrefs of the form ```refs/my/refpath```. All provided parent refs *and* any dereferenced parent refs\nare used to generate default target refs.\nIf any of the target refs already exist, the commits they point to become parents of the created commit.\n- ```-m \"my message\"``` sets the commit message for the snapshot. By default, \"snapshot \" is used. \n- ```-r path/to/repo``` can be provided to specify a repository outside of the current working directory.\n\n```bash\n$ cd path/to/repo\n$ git branch\n* master\n$ lethe\n```\nis equivalent to\n```bash\nlethe -r path/to/repo -p HEAD\n```\nor\n```bash\nlethe -r path/to/repo -p HEAD -p refs/heads/master -t refs/lethe/HEAD -t refs/lethe/master\n```\n\n### Creating a commit programmatically\n```python\nimport lethe\nREPO = '/path/to/repo'\n\ncommit_sha = lethe.snap(cwd=REPO)\ntree_sha = lethe.get_tree(commit_sha, cwd=REPO)\n\nprint('Created new commit with hash ' + commit_sha + ' aka refs/lethe/HEAD')\nprint('Code (tree) state is ' + tree_sha)\n```\n\n\n## Installation\n\nRequirements:\n* python 3 (written and tested with 3.6)\n* git (accessible on the system ```PATH```)\n\nInstall with pip:\n```bash\npip install lethe \n```\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://mpxd.net/code/jan/lethe", "keywords": "git,snapshot,commit,refs,backup,undo,log,lab notebook,traceability", "license": "", "maintainer": "", "maintainer_email": "", "name": "lethe", "package_url": "https://pypi.org/project/lethe/", "platform": "", "project_url": "https://pypi.org/project/lethe/", "project_urls": { "Homepage": "https://mpxd.net/code/jan/lethe" }, "release_url": "https://pypi.org/project/lethe/0.7/", "requires_dist": [ "typing" ], "requires_python": "", "summary": "Git-based snapshotting", "version": "0.7" }, "last_serial": 5630299, "releases": { "0.5": [ { "comment_text": "", "digests": { "md5": "3e744687180293afc3680730d5c6bfe2", "sha256": "336a7ce1d33b277139fc57ae6dd5fea21d991f0d1f19cb963e263274e9bd8c6e" }, "downloads": -1, "filename": "lethe-0.5-py3-none-any.whl", "has_sig": false, "md5_digest": "3e744687180293afc3680730d5c6bfe2", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 17201, "upload_time": "2019-02-11T09:18:28", "url": "https://files.pythonhosted.org/packages/7c/14/01bec7a8c9dc198e90008ea6ac26f3fb0eef25842ad00a068722de4179ed/lethe-0.5-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "0db068e99244fac5a2ee1400a2da4015", "sha256": "369f33f7a13606f5995a950d3fd286f202b42e30030239b300fdcf10167ac1dd" }, "downloads": -1, "filename": "lethe-0.5.tar.gz", "has_sig": false, "md5_digest": "0db068e99244fac5a2ee1400a2da4015", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4772, "upload_time": "2019-02-11T09:18:30", "url": "https://files.pythonhosted.org/packages/28/00/3f38921b9ef8d363eaa352ae00353d6518d7257bb07352750306369ca168/lethe-0.5.tar.gz" } ], "0.6": [ { "comment_text": "", "digests": { "md5": "2ebe2ed34540c1802bdafc8864908156", "sha256": "1c9fc7db5379c8e8b78dce0c865e37bae40dc507c50cfb65ae97fbd65b7327f5" }, "downloads": -1, "filename": "lethe-0.6-py3-none-any.whl", "has_sig": false, "md5_digest": "2ebe2ed34540c1802bdafc8864908156", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 17243, "upload_time": "2019-03-31T19:17:15", "url": "https://files.pythonhosted.org/packages/6e/00/7c6a5f96b09b1c664dcbebea05baef12d2e860fccefa2eb3f791bd77e215/lethe-0.6-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "bb0e89fad5c53713ae02332fc16c271a", "sha256": "b33aa8fb5fcaf2f89657a55c051ba4e7cdb8fcd4aedfb1865963f1046f5fc267" }, "downloads": -1, "filename": "lethe-0.6.tar.gz", "has_sig": false, "md5_digest": "bb0e89fad5c53713ae02332fc16c271a", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4812, "upload_time": "2019-03-31T19:17:17", "url": "https://files.pythonhosted.org/packages/43/1e/d3088f5fa30e458d82d7aadc03f5ebede363c17c47743cfb664e5f96b3ab/lethe-0.6.tar.gz" } ], "0.7": [ { "comment_text": "", "digests": { "md5": "3554e209c8ed80cfc758c4ce9a3a8ba3", "sha256": "83f528227de7d0caef51e31385bd39d57eb3d620593db069201784875373cd52" }, "downloads": -1, "filename": "lethe-0.7-py3-none-any.whl", "has_sig": false, "md5_digest": "3554e209c8ed80cfc758c4ce9a3a8ba3", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 17374, "upload_time": "2019-08-04T10:23:54", "url": "https://files.pythonhosted.org/packages/f5/dd/ce33948c48a8d5910259a06e1d23f35e6ab72648092aaec7e178fb366339/lethe-0.7-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "42e98ed23a9675176bd8ad5149dace36", "sha256": "bd6376cddd796428f3190519fb8032398fe07902b3b705aa14ff31688a5a65b1" }, "downloads": -1, "filename": "lethe-0.7.tar.gz", "has_sig": false, "md5_digest": "42e98ed23a9675176bd8ad5149dace36", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4951, "upload_time": "2019-08-04T10:23:56", "url": "https://files.pythonhosted.org/packages/49/50/e8371365bc75f5d23f960b748a81e095b3998bbe45fb4985cc9927942ff0/lethe-0.7.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "3554e209c8ed80cfc758c4ce9a3a8ba3", "sha256": "83f528227de7d0caef51e31385bd39d57eb3d620593db069201784875373cd52" }, "downloads": -1, "filename": "lethe-0.7-py3-none-any.whl", "has_sig": false, "md5_digest": "3554e209c8ed80cfc758c4ce9a3a8ba3", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 17374, "upload_time": "2019-08-04T10:23:54", "url": "https://files.pythonhosted.org/packages/f5/dd/ce33948c48a8d5910259a06e1d23f35e6ab72648092aaec7e178fb366339/lethe-0.7-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "42e98ed23a9675176bd8ad5149dace36", "sha256": "bd6376cddd796428f3190519fb8032398fe07902b3b705aa14ff31688a5a65b1" }, "downloads": -1, "filename": "lethe-0.7.tar.gz", "has_sig": false, "md5_digest": "42e98ed23a9675176bd8ad5149dace36", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4951, "upload_time": "2019-08-04T10:23:56", "url": "https://files.pythonhosted.org/packages/49/50/e8371365bc75f5d23f960b748a81e095b3998bbe45fb4985cc9927942ff0/lethe-0.7.tar.gz" } ] }