]> gitweb.fluxo.info Git - keyringer.git/commitdiff
Comments
authorSilvio Rhatto <rhatto@riseup.net>
Sat, 18 Sep 2010 16:34:34 +0000 (13:34 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Sat, 18 Sep 2010 16:34:34 +0000 (13:34 -0300)
lib/keyringer/functions
share/keyringer/edit
share/keyringer/genpair

index 630f5192cf1ef98ac2e74a536a5927a3997f4715..a2a35be68ce78e88aa49005e1afb4ec29a7540eb 100644 (file)
@@ -24,6 +24,7 @@ function keyringer_config_load {
   keyringer_config_load_preferences
 }
 
+# Load config preferences
 function keyringer_config_load_preferences {
   # Load custom keyring preferences
   if [ ! -z "$PREFERENCES" ] && [ -f "$PREFERENCES" ]; then
index bee1d7bcca4cbbadb48b952f4ef8b5d9f1c81cfe..edeb693c14549fbb2f04c2a222d1178097602978 100755 (executable)
@@ -11,6 +11,7 @@ keyringer_set_env $*
 # Get file
 keyringer_get_file $2
 
+# Warn user
 echo "Make sure that $BASEDIR is atop of an encrypted volume."
 
 # Set a tmp file
@@ -20,6 +21,7 @@ trap "keyringer_unset_tmpfile $TMPFILE ; exit" INT TERM EXIT
 # Decrypt the information to the file
 gpg --yes -o $TMPFILE --use-agent -d $KEYDIR/$FILE
 
+# Prompt
 echo "Press any key to open the decrypted data into $EDITOR, Ctrl-C to abort"
 read key
 $EDITOR $TMPFILE
index 6de4b4e461563bbc4604096428bf108e536b41e3..cc54ba818c524aa4908b6177c7ccf737f4648095 100755 (executable)
@@ -138,6 +138,10 @@ fi
 
 # Prepare
 mkdir -p $KEYDIR && chmod 700 $KEYDIR
+
+WORK="`keyringer_set_tmpfile genpair`"
+trap "keyringer_unset_tmpfile $WORK; exit" INT TERM EXIT
+
 WORK="`mktemp -d $KEYDIR/genpair.XXXXXX`"
 if [ "$?" != "0" ]; then
   echo "Error setting up $WORK"