made monkeysphere --gen-subkey work better for users without gpg keys.
[monkeysphere.git] / src / monkeysphere
index 4a611c806e4ea8dd3d4405a643821b543d0aef44..8ddfe7fdc93513d5552c93f40407206777f85825 100755 (executable)
@@ -101,6 +101,11 @@ gen_subkey(){
     else
        keyID="$1"
     fi
+    if [ -z "$keyID" ] ; then
+       failure "You have no secret key available.  You should create an OpenPGP
+key before joining the monkeysphere. You can do this with:
+   gpg --gen-key"
+    fi
 
     # get key output, and fail if not found
     gpgOut=$(gpg --quiet --fixed-list-mode --list-secret-keys --with-colons \