aboutsummaryrefslogtreecommitdiff
path: root/dotfiles/cheat/borg
diff options
context:
space:
mode:
authorneodarz <neodarz@neodarz.net>2019-09-05 07:05:07 +0200
committerneodarz <neodarz@neodarz.net>2019-09-05 07:05:07 +0200
commite0c0d4b38cde20e2300e86b69414dd9851b47456 (patch)
tree5df65243447352a9637d1f783247bfd5ccff2ef4 /dotfiles/cheat/borg
parentdc45bf89a66ec6c8cd25cf5605deb853f6984705 (diff)
downloaddotfiles_dotdrop-e0c0d4b38cde20e2300e86b69414dd9851b47456.tar.xz
dotfiles_dotdrop-e0c0d4b38cde20e2300e86b69414dd9851b47456.zip
ooo
Diffstat (limited to 'dotfiles/cheat/borg')
-rw-r--r--dotfiles/cheat/borg23
1 files changed, 23 insertions, 0 deletions
diff --git a/dotfiles/cheat/borg b/dotfiles/cheat/borg
new file mode 100644
index 0000000..c5747da
--- /dev/null
+++ b/dotfiles/cheat/borg
@@ -0,0 +1,23 @@
+# init
+borg init --encryption=repokey /path/to/repo
+
+# first commit
+borg create /path/to/repo::Monday ~/src ~/Documents
+
+# update archive
+borg create --stats /path/to/repo::Tuesday ~/src ~/Documents
+
+# For archive name with data instead of simple name
+borg create /Backups/Docs_importants::{now:%Y-%m-%d-%H:%M:%S.%f} ~/Docs_importants
+
+# Example
+borg create -C lzma,6 ~/Backups/Docs_importants::{now:%Y-%m-%d-%H:%M:%S.%f} ~/Docs_importants
+
+# Tips
+borg save fullpath, so if already in subfolder, remove some leading path elements
+with `strip-components`. Exemple:
+
+borg extract --strip-components 3 ~/Backups/Docs_importants::2018-07-01-13:29:05.247461
+
+# compression
+lz4 < zstd < zlib < lzma