Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gopass show -o is ineffective #1821

Closed
mcnesium opened this issue Mar 4, 2021 · 2 comments · Fixed by #1822
Closed

gopass show -o is ineffective #1821

mcnesium opened this issue Mar 4, 2021 · 2 comments · Fixed by #1822
Assignees

Comments

@mcnesium
Copy link

mcnesium commented Mar 4, 2021

When you want to really only have the password (e.g. for a script), gopass show has the --password, -o option:

m@x ~ gopass help show | grep only
--password, -o             Display only the password. Takes precedence over all other flags. (default: false)

However, this flag does not do anything, unfortunately. Here is a minimal example:

m@x ~ gopass generate testpassword 31
✅ Password for entry "testpassword" generated
✔ Copied testpassword to clipboard. Will clear in 45 seconds.
2
Copied to clipboard

m@x ~ gopass show testpassword 
Secret: testpassword

iEg2h6skkaL74iHCwRm92hbtCOLYmcw

m@x ~ gopass show -o testpassword 
Secret: testpassword

iEg2h6skkaL74iHCwRm92hbtCOLYmcw

mcn@x270 ~ gopass show --password testpassword 
Secret: testpassword

iEg2h6skkaL74iHCwRm92hbtCOLYmcw

The actual file instead only contains one line with the password:

m@x ~ gpg -qd .local/share/passwordstore/testpassword.gpg 
iEg2h6skkaL74iHCwRm92hbtCOLYmcw

This gopass is installed from Arch community repo

m@x ~ gopass --version
gopass 1.12.0 (2021-02-11 21:15:26) go1.15.8 linux amd64
@dominikschulz
Copy link
Member

Ah, my bad. This might be my fault.

Should be easy to fix.

@dominikschulz dominikschulz self-assigned this Mar 4, 2021
dominikschulz added a commit to dominikschulz/gopass that referenced this issue Mar 4, 2021
Do not print the output header when --password/-o is given.

RELEASE_NOTES=[BUGFIX] Fix -o

Fixes gopasspw#1821

Signed-off-by: Dominik Schulz <dominik.schulz@gauner.org>
AnomalRoil pushed a commit that referenced this issue Mar 5, 2021
Do not print the output header when --password/-o is given.

RELEASE_NOTES=[BUGFIX] Fix -o

Fixes #1821

Signed-off-by: Dominik Schulz <dominik.schulz@gauner.org>
@mcnesium
Copy link
Author

mcnesium commented Mar 5, 2021

thanks for jumping right in! 👍

kpitt pushed a commit to kpitt/gopass that referenced this issue Jul 21, 2022
Do not print the output header when --password/-o is given.

RELEASE_NOTES=[BUGFIX] Fix -o

Fixes gopasspw#1821

Signed-off-by: Dominik Schulz <dominik.schulz@gauner.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants