From c10fdd5e50d1543196e0aeb29ee8032f0ad5aa0b Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Thu, 14 Nov 2013 15:02:56 -0200 Subject: Warn user if keyringer_shred is using rm --- lib/keyringer/functions | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/keyringer/functions b/lib/keyringer/functions index fcec045..4d97f34 100755 --- a/lib/keyringer/functions +++ b/lib/keyringer/functions @@ -148,6 +148,7 @@ function keyringer_set_tmpfile { function keyringer_shred { local path="$1" local tool + local message="Removing" if [ -z "$path" ]; then return @@ -160,10 +161,11 @@ function keyringer_shred { tool="shred" else # Worst implementation + message="WARNING $message" tool="rm" fi - echo "Removing $path using $tool..." + echo "$message $path using $tool..." if [ -d "$path" ]; then find $path -exec $tool -f {} \; -- cgit v1.2.3