resticpy


Nameresticpy JSON
Version 1.0.4 PyPI version JSON
download
home_pagehttps://github.com/mtlynch/resticpy.git
SummaryRestic backup Python wrapper
upload_time2023-12-02 20:21:39
maintainer
docs_urlNone
authorMichael Lynch
requires_python>=3.7
licenseMIT
keywords backup
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # resticpy

[![PyPI](https://img.shields.io/pypi/v/resticpy)](https://pypi.org/project/resticpy/)
[![CircleCI](https://circleci.com/gh/mtlynch/resticpy.svg?style=svg)](https://circleci.com/gh/mtlynch/resticpy)
[![Coverage Status](https://coveralls.io/repos/github/mtlynch/resticpy/badge.svg?branch=master)](https://coveralls.io/github/mtlynch/resticpy?branch=master)
[![License](http://img.shields.io/:license-mit-blue.svg?style=flat-square)](LICENSE)

## Overview

Minimal Python wrapper around the [restic](https://restic.readthedocs.io/) backup command-line interface.

## Installation

### From pip

```bash
pip install resticpy
```

### From source

```bash
git clone https://github.com/mtlynch/resticpy.git
cd resticpy
pip install .
```

## Quick start

### Create a password file

```bash
printf "mysecretpass" > password.txt
```

### Initialize a repository and back up a file

```python
import restic

restic.repository = '/tmp/backup1'
restic.password_file = 'password.txt'

restic.init()
restic.backup(paths=['some-file.txt'])
```

### Restore a snapshot

```python
import restic

restic.repository = '/tmp/backup1'
restic.password_file = 'password.txt'

restic.restore(snapshot_id='latest', target_dir='~/restored')
```

## API Documentation

<https://mtlynch.github.io/resticpy/>

## Example

I personally use this library for my backups. I've published my backup script at [mtlynch/mtlynch-backup](https://github.com/mtlynch/mtlynch-backup).

## Compatibility

resticpy is tested against [restic 0.16.0](https://github.com/restic/restic/releases/tag/v0.16.0).

## resticpy's scope and future

resticpy is maintained by [Michael Lynch](https://mtlynch.io) as a hobby project.

resticpy is **not** meant to achieve feature parity with restic. It is meant to cover a small subset of the most useful features of restic.

Due to time limitations, I keep resticpy's scope limited to only the features that fit into my workflows.

### Feature requests

I don't fulfill feature requests for resticpy. You are welcome to file a feature request for a third-party contributor to take on.

### Pull requests

I accept pull requests when they are:

- Documented
- Tested
- Small

I don't accept pull requests for features that look like they'll be a large maintenance burden.

## Acknowledgments

This project is forked from [jstzwj/PyRestic](https://github.com/jstzwj/PyRestic).



            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/mtlynch/resticpy.git",
    "name": "resticpy",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.7",
    "maintainer_email": "",
    "keywords": "backup",
    "author": "Michael Lynch",
    "author_email": "michael@mtlynch.io",
    "download_url": "https://files.pythonhosted.org/packages/40/3a/a3b7a108c743f141da437c75de1c911b97471610cd6a5b9f8ef23680a0d4/resticpy-1.0.4.tar.gz",
    "platform": null,
    "description": "# resticpy\n\n[![PyPI](https://img.shields.io/pypi/v/resticpy)](https://pypi.org/project/resticpy/)\n[![CircleCI](https://circleci.com/gh/mtlynch/resticpy.svg?style=svg)](https://circleci.com/gh/mtlynch/resticpy)\n[![Coverage Status](https://coveralls.io/repos/github/mtlynch/resticpy/badge.svg?branch=master)](https://coveralls.io/github/mtlynch/resticpy?branch=master)\n[![License](http://img.shields.io/:license-mit-blue.svg?style=flat-square)](LICENSE)\n\n## Overview\n\nMinimal Python wrapper around the [restic](https://restic.readthedocs.io/) backup command-line interface.\n\n## Installation\n\n### From pip\n\n```bash\npip install resticpy\n```\n\n### From source\n\n```bash\ngit clone https://github.com/mtlynch/resticpy.git\ncd resticpy\npip install .\n```\n\n## Quick start\n\n### Create a password file\n\n```bash\nprintf \"mysecretpass\" > password.txt\n```\n\n### Initialize a repository and back up a file\n\n```python\nimport restic\n\nrestic.repository = '/tmp/backup1'\nrestic.password_file = 'password.txt'\n\nrestic.init()\nrestic.backup(paths=['some-file.txt'])\n```\n\n### Restore a snapshot\n\n```python\nimport restic\n\nrestic.repository = '/tmp/backup1'\nrestic.password_file = 'password.txt'\n\nrestic.restore(snapshot_id='latest', target_dir='~/restored')\n```\n\n## API Documentation\n\n<https://mtlynch.github.io/resticpy/>\n\n## Example\n\nI personally use this library for my backups. I've published my backup script at [mtlynch/mtlynch-backup](https://github.com/mtlynch/mtlynch-backup).\n\n## Compatibility\n\nresticpy is tested against [restic 0.16.0](https://github.com/restic/restic/releases/tag/v0.16.0).\n\n## resticpy's scope and future\n\nresticpy is maintained by [Michael Lynch](https://mtlynch.io) as a hobby project.\n\nresticpy is **not** meant to achieve feature parity with restic. It is meant to cover a small subset of the most useful features of restic.\n\nDue to time limitations, I keep resticpy's scope limited to only the features that fit into my workflows.\n\n### Feature requests\n\nI don't fulfill feature requests for resticpy. You are welcome to file a feature request for a third-party contributor to take on.\n\n### Pull requests\n\nI accept pull requests when they are:\n\n- Documented\n- Tested\n- Small\n\nI don't accept pull requests for features that look like they'll be a large maintenance burden.\n\n## Acknowledgments\n\nThis project is forked from [jstzwj/PyRestic](https://github.com/jstzwj/PyRestic).\n\n\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Restic backup Python wrapper",
    "version": "1.0.4",
    "project_urls": {
        "Homepage": "https://github.com/mtlynch/resticpy.git",
        "repository": "https://github.com/mtlynch/resticpy"
    },
    "split_keywords": [
        "backup"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "b5ee5494b5441664e32cd99465fc677fa61a8f88977a64d390e4a20a3d912430",
                "md5": "1867a3b2e063fc504a9c7fbb30bc1494",
                "sha256": "cfcbef73c49553ed29766632fa31b7ec665eeef60ba3fcf686c27d10a0b6c783"
            },
            "downloads": -1,
            "filename": "resticpy-1.0.4-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "1867a3b2e063fc504a9c7fbb30bc1494",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.7",
            "size": 24625,
            "upload_time": "2023-12-02T20:21:37",
            "upload_time_iso_8601": "2023-12-02T20:21:37.477011Z",
            "url": "https://files.pythonhosted.org/packages/b5/ee/5494b5441664e32cd99465fc677fa61a8f88977a64d390e4a20a3d912430/resticpy-1.0.4-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "403aa3b7a108c743f141da437c75de1c911b97471610cd6a5b9f8ef23680a0d4",
                "md5": "cb01f0e0338ed9aeefd7626c7a86bb7a",
                "sha256": "e64817b3acc109b7c3efe4f7876d8b2518f086eaf3100ed299a04e46170f940a"
            },
            "downloads": -1,
            "filename": "resticpy-1.0.4.tar.gz",
            "has_sig": false,
            "md5_digest": "cb01f0e0338ed9aeefd7626c7a86bb7a",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.7",
            "size": 13040,
            "upload_time": "2023-12-02T20:21:39",
            "upload_time_iso_8601": "2023-12-02T20:21:39.356815Z",
            "url": "https://files.pythonhosted.org/packages/40/3a/a3b7a108c743f141da437c75de1c911b97471610cd6a5b9f8ef23680a0d4/resticpy-1.0.4.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-12-02 20:21:39",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "mtlynch",
    "github_project": "resticpy",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "circle": true,
    "lcname": "resticpy"
}
        
Elapsed time: 0.14463s