aboutsummaryrefslogtreecommitdiff
path: root/lib/keyringer/functions
diff options
context:
space:
mode:
Diffstat (limited to 'lib/keyringer/functions')
-rw-r--r--lib/keyringer/functions10
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/keyringer/functions b/lib/keyringer/functions
index 9c37291..67bbc50 100644
--- a/lib/keyringer/functions
+++ b/lib/keyringer/functions
@@ -213,6 +213,16 @@ function keyringer_get_file {
fi
}
+# Get a new file argument
+function keyringer_get_new_file {
+ FILE="`keyringer_filename $1`"
+
+ if [ -z "$FILE" ]; then
+ keyringer_action_usage
+ exit 1
+ fi
+}
+
# Run the action usage
function keyringer_action_usage {
if [ "`type -t "keyringer_usage_$BASENAME"`" == "function" ]; then