From a98cfe4f8f093e88a22d8c7f4a7d10798ed20264 Mon Sep 17 00:00:00 2001 From: Marco Cetica Date: Tue, 14 Mar 2023 09:19:17 +0100 Subject: [PATCH] Made destination dir modular --- README.md | 20 ++++++++++---------- backup.sh | 24 +++++++++++++----------- 2 files changed, 23 insertions(+), 21 deletions(-) diff --git a/README.md b/README.md index 64a0644..b80a07a 100644 --- a/README.md +++ b/README.md @@ -13,7 +13,7 @@ $> sudo make install This will copy `backup.sh` into `/usr/local/bin/backup.sh`, `backup_sources.bk` into `/usr/local/etc/backup_sources.bk` and `backup.sh.1` into `/usr/local/share/man/man1`. -At this point you still need to install the dependencies: +At this point you still need to install the following dependencies: - `rsync` - `tar` - `openssl` @@ -25,7 +25,7 @@ backup.sh - POSIX compliant, modular and lightweight backup utility. Syntax: ./backup.sh [-b|-e|-h] options: --b|--backup SOURCES USER PASS Backup folders from SOURCES file. +-b|--backup SOURCES DEST PASS Backup folders from SOURCES file. -e|--extract ARCHIVE PASS Extract ARCHIVE using PASS. -h|--help Show this helper. ``` @@ -34,7 +34,7 @@ As you can see, `backup.sh` supports two options: **backup creation** and **arch root permissions, while the latter does not. Let us see them in details. ### Backup creation -To specify the directories to backup, `backup.sh` uses an associative array called +To specify the directories to backup, `backup.sh` uses an associative array defined in a text file(called _sources file_) with the following syntax: ```text @@ -42,7 +42,7 @@ defined in a text file(called _sources file_) with the following syntax: ``` Where `