{ "info": { "author": "Sunyeop Lee", "author_email": "sunyeop97@gmail.com", "bugtrack_url": null, "classifiers": [], "description": "[![TravisCI](https://img.shields.io/travis/qbx2/pscp/master.svg?style=flat)](https://travis-ci.org/qbx2/pscp/)\n[![PyPI](https://img.shields.io/pypi/v/pscp.svg?style=flat)](https://pypi.org/project/pscp)\n![PyPI-License](https://img.shields.io/pypi/l/pscp.svg?style=flat)\n[![codecov](https://codecov.io/gh/qbx2/pscp/branch/master/graph/badge.svg)](https://codecov.io/gh/qbx2/pscp)\n\n# PSCP: Per-session checkpoint\n\nPSCP is a brand-new way to make checkpoint in git repository efficiently.\nBy logging the hash output by `pscp.create()`, you can `git diff`, `git stash branch` and `git checkout` using them whenever you want.\nPSCP is framework-agnostic, so can be used in any git repository.\n\nPSCP inherits all strengths from git, which are very useful for study.\n\n* Recycle unchanged objects\n* Compression (zlib)\n* Show differences using `git diff a..b`\n* Checkout to, using `git checkout`\n* Create branch from, using `git stash branch`. This restores staged files staged and unstaged files unstaged.\n\nBesides, PSCP does make neither `git log` nor `git stash list` messy. You won't suffer from trivial tuning commits and too many stashes.\n\n## Requirements\n\n* python 3.5+\n* git\n\n## Installation\n\n`pip install pscp`\n\n## Getting Started (with [tensorboardX](https://github.com/lanpa/tensorboardX))\n\n[Getting Started](Getting_Started.md)\n\n## Frequently Asked Questions\n\n### How does it work?\n\n[How PSCP Works](How_PSCP_Works.md)\n\n### Tracking New Files\n\nUse `git add` to stage, to track new files. Untracked files will not be added to the checkpoint.\n\n### Saving environment variables or argparse results?\n\nYou're supposed to write to any file and track them (using `git add`).\nUsing json built-in library, it can be done easily.\n\n```python\nimport json\n```\n\nTo save environment variables,\n\n```python\nimport os\njson.dump(fp, dict(os.environ), indent=4)\n```\n\nTo save argparse namespace,\n\n```python\njson.dump(fp, vars(args), indent=4)\n```\n\nAny other data can be saved in same way.\n\n## Command Line Tool (TODO)\n\n`python -m pscp`\n\n## pscp.create(return\\_head\\_on\\_nothing=True, return\\_format='abbrev', link=True)\n\nCreate per-session checkpoint.\n\n* `return_head_on_nothing`: If True, return hash of `HEAD` when there are nothing changed compared to `HEAD`, otherwise, return `None`.\n* `return_format`\n\t* `abbrev`, `short`: Return abbreviated hash.\n\t* `long`: Return just unabbreviated hash.\n\t* `ref`: Return refspec. Raises exception when link == False.\n* `link`: See `pscp.link()` below.\n\n## pscp.link(hash, refspec=None)\n\nCreate reference. `pscp.link()` could be used to avoid pruning on garbage collection.\n\n* `hash`: The hash to be referenced.\n* `refspec`: If `None`, `refs/pscp/{timestamp_ms}` is used.\n\n## pscp.delete(refspec)\n\nDelete pscp reference. Call `pscp.gc()` if you want.\n\n* `refspec`: Target refspec to be deleted. `timestamp_ms` is also allowed.\n\n## pscp.gc(prune='now')\n\nRun `git gc --prune=`.\n\n## pscp.push(refspec=None, repository='origin')\n\nPush checkpoint to the remote repository.\n\n* `refspec`: If `None`, all checkpoints are pushed.\n\n## pscp.fetch(refspec=None, refmap=None, repository='origin')\n\n* `refspec`: If `None`, all checkpoints are fetched.\n* `refmap`: If `None`, `refs/pscp/*:refs/pscp/*` is used.", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/qbx2/pscp", "keywords": "", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "pscp", "package_url": "https://pypi.org/project/pscp/", "platform": "", "project_url": "https://pypi.org/project/pscp/", "project_urls": { "Homepage": "https://github.com/qbx2/pscp" }, "release_url": "https://pypi.org/project/pscp/0.0.3/", "requires_dist": null, "requires_python": ">=3.5", "summary": "Per-session checkpoint using git-stash-create", "version": "0.0.3" }, "last_serial": 4790893, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "21430b2fa970ef5b8325127412ac1dbc", "sha256": "a1caa26b3690309355776b12eac59c6cefd19e81338ceb3e8490639421766262" }, "downloads": -1, "filename": "pscp-0.0.1.tar.gz", "has_sig": false, "md5_digest": "21430b2fa970ef5b8325127412ac1dbc", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5", "size": 5033, "upload_time": "2019-02-06T10:42:31", "url": "https://files.pythonhosted.org/packages/76/9a/5feaf5a7f3c2a04a6977ba1e23a552ea58775fe724b0bbd31fb3ee581d3d/pscp-0.0.1.tar.gz" } ], "0.0.2": [ { "comment_text": "", "digests": { "md5": "ebdbc80bdd75e469def46f2271442259", "sha256": "56e54dd8eaac8bcbb0bc32074a39a181d24cc74735c7573c54cd8cc7de717058" }, "downloads": -1, "filename": "pscp-0.0.2.tar.gz", "has_sig": false, "md5_digest": "ebdbc80bdd75e469def46f2271442259", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5", "size": 3511, "upload_time": "2019-02-07T06:10:52", "url": "https://files.pythonhosted.org/packages/7e/3e/3541bd812a83d3a48e4a384a8e21347743aeec2917f9b4834e5c4493c834/pscp-0.0.2.tar.gz" } ], "0.0.3": [ { "comment_text": "", "digests": { "md5": "110c9825c37b337dc20b322460dd1fc9", "sha256": "6679a8f4944cc432e90df4b380d3af28d5dd7df0b99c3e7c6e05dde877db9e0e" }, "downloads": -1, "filename": "pscp-0.0.3.tar.gz", "has_sig": false, "md5_digest": "110c9825c37b337dc20b322460dd1fc9", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5", "size": 3882, "upload_time": "2019-02-07T13:13:31", "url": "https://files.pythonhosted.org/packages/6b/e3/5cd834360ea8224a758267442e0a59066da9cf769d2f549e813fefaffcec/pscp-0.0.3.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "110c9825c37b337dc20b322460dd1fc9", "sha256": "6679a8f4944cc432e90df4b380d3af28d5dd7df0b99c3e7c6e05dde877db9e0e" }, "downloads": -1, "filename": "pscp-0.0.3.tar.gz", "has_sig": false, "md5_digest": "110c9825c37b337dc20b322460dd1fc9", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5", "size": 3882, "upload_time": "2019-02-07T13:13:31", "url": "https://files.pythonhosted.org/packages/6b/e3/5cd834360ea8224a758267442e0a59066da9cf769d2f549e813fefaffcec/pscp-0.0.3.tar.gz" } ] }