Add support to switch out password source binary

There is now a new configuration entry option `password-source-binary`,
which allows to use an alternate binary for the gopass/pass password
source.

If the option is not specified, we will fallback to `pass` (for `pass`)
and `gopass` (for `gopass`).
This commit is contained in:
Patrick Pichler
2019-10-03 08:30:26 +02:00
parent 590244947b
commit 659a5c8e74
3 changed files with 39 additions and 4 deletions
+16
View File
@@ -374,3 +374,19 @@ When `password-source` is set to `stdin`, the `jira login` command will read fro
```bash
$ ./password-generator | jira login --endpoint=https://my.jira.endpoint.com --user=USERNAME
```
#### Switch binary used for password source
For `gopass` and `pass` it is possible to switch the binary used for retrieval of the password. This can be accomplised
by setting the `password-source-binary` option in the configuration file.
E.g.
```yaml
password-source: gopass
password-name: jira.example.com/myuser
password-source-binary: my-special-gopass
```
This will cause go-jira to use the `gopass` style cli interaction with the `my-special-gopass` binary.
If you ommit the `password-source-binary` option, either `gopass` (for `gopass`) or `pass` (for `pass`)
will be used.