Skip to main content

Presets library for Backup-chan.

Project description

Backup-chan presets

This is a library for creating presets for backups. A preset allows to define the destination target and what file on the system to upload, under a unique name.

Installing

# The easy way
pip install backupchan-presets

# Installing from source
git clone https://github.com/Backupchan/presets.git backupchan-presets
cd backupchan-presets
pip install .

Testing

pytest

Example usage

from backupchan_presets import Presets
from backupchan import API

api = API("host", 8000, "api-key")

# Create a new preset.
presets = Presets()
presets.add("myPreset", "00000000-0000-0000-0000-000000", "/home/me/Documents/stuff")
presets.save() # Save it into the configuration file.
presets["myPreset"].upload(api, False)

# Or load existing presets from a file.
presets.load()
presets["anotherPreset"].upload(api, False)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

backupchan_presets-0.3.0.tar.gz (5.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

backupchan_presets-0.3.0-py3-none-any.whl (4.7 kB view details)

Uploaded Python 3

File details

Details for the file backupchan_presets-0.3.0.tar.gz.

File metadata

  • Download URL: backupchan_presets-0.3.0.tar.gz
  • Upload date:
  • Size: 5.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.5

File hashes

Hashes for backupchan_presets-0.3.0.tar.gz
Algorithm Hash digest
SHA256 0a7dee9f4f3b4037bbc3148c05926a797b542061b03aff637dd10d653702cdda
MD5 21f5984029c1eb0f71d3bae8d5235d62
BLAKE2b-256 0e4cc269572a7fd46cbe5731ee09b089501f227d05ef4591dfe3554d40bbbc21

See more details on using hashes here.

File details

Details for the file backupchan_presets-0.3.0-py3-none-any.whl.

File metadata

File hashes

Hashes for backupchan_presets-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 59f4c302997060d7ccccbfc190ba5f1d14b7586c6a0ff0873f2dad1847e6644a
MD5 d89badc77c604c368c2ad97c311097b4
BLAKE2b-256 843b5e7db2d291fd9e996b4b364ca196e52296ee632b75edfc47d69875c1da29

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page