aboutsummaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
Diffstat (limited to 'config')
-rw-r--r--config/config.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/config/config.go b/config/config.go
index e925be3..7454d7a 100644
--- a/config/config.go
+++ b/config/config.go
@@ -1,6 +1,7 @@
package config
import (
+ "code.laria.me/petrific/gpg"
"fmt"
"github.com/BurntSushi/toml"
"github.com/adrg/xdg"
@@ -32,6 +33,10 @@ func LoadConfig(path string) (config Config, err error) {
return
}
+func (c Config) GPGSigner() gpg.Signer {
+ return gpg.Signer{c.Signing.Key}
+}
+
// Get gets a value from the StorageConfig, taking care about type checking.
// ptr must be a pointer or this method will panic.
// ptr will only be changed, if returned error != nil