From 44c6a28ca5b8f5c13886f24ea8ceec5eae5ee1b1 Mon Sep 17 00:00:00 2001 From: Marco Bernasocchi Date: Thu, 10 Apr 2014 17:36:14 +0200 Subject: [PATCH] Update dhsnapshot.pl fixes #3 --- dhsnapshot.pl | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/dhsnapshot.pl b/dhsnapshot.pl index 1d3ebc3..6399dd3 100755 --- a/dhsnapshot.pl +++ b/dhsnapshot.pl @@ -6,7 +6,12 @@ $conf{'basedir'} = get_basedir(); $conf{'emptydir'} = "$conf{'basedir'}/__emptydir/"; -require 'dhsnapshot.conf'; +use File::Basename; +use Cwd 'abs_path'; +my $bd = dirname(abs_path($0)); +my $conf_file = "$bd/dhsnapshot.conf"; +require $conf_file; + my $lowest_interval = 'daily'; my %rotation;