From 57a9fceaf20857c36f57a2e53714eda6f7d20093 Mon Sep 17 00:00:00 2001 From: kaotisk Date: Sun, 16 Mar 2025 19:46:26 +0200 Subject: fix: typo in flag --- bin/ak-gpg | 2 ++ lib/_ak_gpg | 8 ++++---- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/bin/ak-gpg b/bin/ak-gpg index 03fee4f..f84bc71 100755 --- a/bin/ak-gpg +++ b/bin/ak-gpg @@ -44,6 +44,7 @@ ## -d, --delete-key Delete GPG keys from your keyring ## -ds, --delete-secret-key ## Delete GPG keys from your keyring +## -r, --run Runs a command with gpg2 ## fullprogrampath="$(realpath $0)" PROGRAM=$(basename $0) @@ -77,6 +78,7 @@ if [ ! -z $1 ]; then --select-key | -s) _ak_gpg_select_key; exit;; --delete-key | -d) _ak_gpg_delete_key; exit;; --delete-secret-key | -ds) shift; _ak_gpg_delete_secret_key $1; exit;; + --run | -r) shift; _ak_gpg $*; exit;; * ) _ak_usage;; esac else _ak_usage diff --git a/lib/_ak_gpg b/lib/_ak_gpg index bdb8829..c8cc669 100755 --- a/lib/_ak_gpg +++ b/lib/_ak_gpg @@ -136,7 +136,7 @@ function _ak_gpg_sign_clear(){ function _ak_gpg_encrypt_sign(){ if [ ! -z $1 ] && [ -n "$1" ] && [ ! -z $2 ] && [ -n "$2" ] && [ ! -z $3 ] && [ -n "$3" ] then - _ak_gpg --sign-with $AK_FINGERPRINT --encypt -r $3 --armor --output $1 $2 + _ak_gpg --sign-with $AK_FINGERPRINT --encrypt -r $3 --armor --output $1 $2 else exit 1 fi @@ -145,7 +145,7 @@ function _ak_gpg_encrypt_sign(){ function _ak_gpg_encrypt_sign_for_self(){ if [ ! -z $1 ] && [ -n "$1" ] && [ ! -z $2 ] && [ -n "$2" ] then - _ak_gpg --sign-with $AK_FINGERPRINT --encypt -r $AK_FINGERPRINT --armor --output $1 $2 + _ak_gpg --sign-with $AK_FINGERPRINT --encrypt -r $AK_FINGERPRINT --armor --output $1 $2 else exit 1 fi @@ -154,7 +154,7 @@ function _ak_gpg_encrypt_sign_for_self(){ function _ak_gpg_encrypt(){ if [ ! -z $1 ] && [ -n "$1" ] && [ ! -z $2 ] && [ -n "$2" ] && [ ! -z $3 ] && [ -n "$3" ] then - _ak_gpg --encypt -r $3 --armor --output $1 $2 + _ak_gpg --encrypt -r $3 --armor --output $1 $2 else exit 1 fi @@ -163,7 +163,7 @@ function _ak_gpg_encrypt(){ function _ak_gpg_encrypt_for_self(){ if [ ! -z $1 ] && [ -n "$1" ] && [ ! -z $2 ] && [ -n "$2" ] then - _ak_gpg --encypt -r $AK_FINGERPRINT --armor --output $1 $2 + _ak_gpg --encrypt -r $AK_FINGERPRINT --armor --output $1 $2 else exit 1 fi -- cgit v1.2.3