fix gpg subkey support typo

initremote, enableremote: Really support gpg subkeys suffixed with an
exclamation mark, which forces gpg to use a specific subkey. (Previous try
had a bug.)

This commit was sponsored by Jake Vosloo on Patreon.
This commit is contained in:
Joey Hess 2017-12-05 13:58:53 -04:00
parent 4e38c4f57f
commit ed701667aa
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
3 changed files with 21 additions and 1 deletions

View file

@ -171,7 +171,7 @@ findPubKeys cmd for
{- "subkey!" tells gpg to force use of a specific subkey -}
isForcedSubKey :: String -> Bool
isForcedSubKey s = "!" `isSuffixOf` s && all isHexDigit (drop 1 s)
isForcedSubKey s = "!" `isSuffixOf` s && all isHexDigit (drop 1 (reverse s))
type UserId = String