From cc7bb4f4fe70d5d2249dcd732408edf6e4203093 Mon Sep 17 00:00:00 2001 From: Andinus Date: Wed, 14 Oct 2020 21:29:00 +0530 Subject: Add fallback for $gpg_fingerprint & $gpg_bin --- leo.pl | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'leo.pl') diff --git a/leo.pl b/leo.pl index f079419..5c57686 100755 --- a/leo.pl +++ b/leo.pl @@ -68,8 +68,8 @@ $backup_dir .= "/$ymd"; path($backup_dir)->mkpath; # Create backup directory. -my $gpg_fingerprint = $options{gpg_fingerprint}; -my $gpg_bin = $options{gpg_bin}; +my $gpg_fingerprint = $options{gpg_fingerprint} || "`nil'"; +my $gpg_bin = $options{gpg_bin} || "gpg"; # Print help. HelpMessage() and exit 0 if scalar @ARGV == 0 or $options{help}; @@ -171,11 +171,11 @@ Profile:}; print qq{ Encrypt files with $gpg_fingerprint\n --sign }; - print "[Enabled]" if $options{sign}; + print "[Enabled]" if $options{sign}; print qq{ Sign files with $gpg_fingerprint\n --delete }; - print "[Enabled]" if $options{delete}; + print "[Enabled]" if $options{delete}; print qq{ Delete the tar file after running $gpg_bin\n --verbose -- cgit 1.4.1-2-gfad0