From 36a4a57f386b81033c4a70e1cfd24f6214e68f79 Mon Sep 17 00:00:00 2001 From: Michael Prokop Date: Fri, 9 Mar 2007 19:47:37 +0100 Subject: [PATCH] dirvish-setup: support setting of tree on the client --- debian/changelog | 7 +++++++ usr_sbin/dirvish-setup | 9 +++++++-- 2 files changed, 14 insertions(+), 2 deletions(-) diff --git a/debian/changelog b/debian/changelog index ccae1a8..209cc09 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +grml-scripts (0.9.22) unstable; urgency=low + + * dirvish-setup: support setting of tree (directory) that should + be included in the backup. + + -- Michael Prokop Fri, 9 Mar 2007 19:46:11 +0100 + grml-scripts (0.9.21) unstable; urgency=low * Fix for myip, thanks to wuehlmaus and schula. diff --git a/usr_sbin/dirvish-setup b/usr_sbin/dirvish-setup index 51b7a11..d81bf34 100755 --- a/usr_sbin/dirvish-setup +++ b/usr_sbin/dirvish-setup @@ -4,7 +4,7 @@ # Authors: grml-team (grml.org), (c) Michael Prokop # Bug-Reports: see http://grml.org/bugs/ # License: This file is licensed under the GPL v2. -# Latest change: Fre Feb 23 23:49:58 CET 2007 [mika] +# Latest change: Fre Mär 09 19:45:57 CET 2007 [mika] ################################################################################ # Ressources: # http://apt-get.dk/howto/backup/ @@ -91,6 +91,10 @@ client_name() { CLIENT="$(dialog --stdout --inputbox 'Please choose the name for your client instance, also known as vault' 0 0 client1)" } +tree_name() { + TREE="$(dialog --stdout --inputbox 'Please choose the directory you want to backup from your client (also known as tree)' 0 0 /home)" +} + create_client_conf() { mkdir -p "${BACKUP_DIR}/${CLIENT}/dirvish" if [ -f "${BACKUP_DIR}/${CLIENT}/dirvish/default.conf" ] ; then @@ -99,7 +103,7 @@ create_client_conf() { cat > "${BACKUP_DIR}/${CLIENT}/dirvish/default.conf" << EOF # Configuration file of client-side for dirvish created by $PN on $(date) client: $CLIENTNAME -tree: /home +tree: $TREE xdev: true index: gzip image-default: %Y-%m-%d @@ -171,6 +175,7 @@ esac get_backup_dir && \ client_name && \ client_setup && \ +tree_name && \ create_client_conf && \ write_conffile && \ display_info -- 2.1.4