Conversation
If STDIN is not interactive, change EDITOR to `cp /dev/stdin`. fixes #33
|
Oh yikes, this breaks another hack of mine where I set (Yes, this is a bit of a spacebar-heating moment, I realize.) |
|
@whentze Can you describe your hack more? |
|
Yes. I have a program like this #!/bin/sh
cp "$2" "$1"and by calling agenix as |
|
Just to be clear, I'm aware this is an awful hack, and I'm not asking you to keep it supported. |
|
This editor program puts the cleartext into a file called cleartext even with these changes. |
|
Huh, even when STDIN is not interactive? |
|
Oh, no STDIN was interactive. I misunderstood what you are doing. Or maybe you edited it to add more after I saw it... 🤷 |
|
Sorry for the edits, I had realized my minimal example was too minimal and didn't actually work. What the hack is really solving for me is the ability to use agenix secrets in a script - locally while working on a repo. |
|
Would you be open to the addition of I can try my hand at an implementation. |
|
Yes, definitely. We're using |
|
@whentze can you provide a sample codeblock for how one would interact with this, to make sure I understand? Is this it? $ agenix [-i /tmp/id_rsa] --decrypt myfile.age
mysecret |
If STDIN is not interactive, change EDITOR to
cp /dev/stdin.Also updates tests somewhat.
fixes #33