FiloSottile / age

A simple, modern and secure encryption tool (and Go library) with small explicit keys, no config options, and UNIX-style composability.
https://age-encryption.org
BSD 3-Clause "New" or "Revised" License
15.79k stars 477 forks source link

cmd/age-keygen: -y should report error if it fails to parse input #437

Closed FiloSottile closed 1 year ago

FiloSottile commented 1 year ago

Discussed in https://github.com/FiloSottile/age/discussions/435

Originally posted by **vbezhenar** July 23, 2022 Right now it does not do that which is confusing: ``` % echo test | age-keygen -y age-keygen: error: failed to parse input: error at line 1: malformed secret key: separator '1' at invalid position: pos=-1, len=4 age-keygen: error: no identities found in the input % echo $? 0 ```
FiloSottile commented 1 year ago

Ah, this is a duplicate of #383. It's already fixed in v1.1.0-rc.1.