-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Add gopass support to qute-pass via a CLI switch #5143
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
Add gopass support to qute-pass via a CLI switch #5143
Conversation
lufte
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It works correctly, and the code looks good.
Here's how I tested it:
1- Moved my current store somewhere else so I don't break anything.
2- Installed gopass and created a new store.
3- Added a password for somesite.
4- Mounted a new store with gopass mounts add store1.
5- Added another password for somesite under store1 with gopass generate store1/somesite/user.
6- Used the new userscript from somesite and it correctly showed me the two options.
Regarding the documentation of the new parameter (which says Executable to start (pass or gopass)) I wonder if we should limit the options of allowed arguments (with choices) or simply remove the (pass or gopass) part, since the code is not really limiting to those two options.
Besides that, looks great.
|
@lufte Wow, thanks for the extensive test and feedback! Re the new start parameter. I wonder whether it could be something like I recon some people could have |
|
How about |
|
The current argument/documentation indeed feels a bit confusing to me - it reads like I could do I can see two ways forward:
I don't really mind either way, so I'll leave it up to you (plural) which one you prefer. |
|
I'd prefer the latter. We could also have |
|
Yip, I think the |
The new CLI-switch --mode makes qute-pass compatible with the gopass password store (https://github.com/gopasspw/gopass). While gopass itself is mostly compatible with pass, it offers the possibility to mount multiple shared password stores. qute-pass way of just traversing PASSWORD_STORE_DIR won't help in that case. Closes qutebrowser#5142
3b8c5b9 to
5bf7c8e
Compare
|
Soooo – once I had everything typed down I noticed that
So, 5bf7c8e adds a simple |
|
@bascht That is okay for me. However, you could also rename |
|
Ah, a fellow force-pusher like myself. I had to dig a little bit to be able to compare exactly what you changed since the last commit, instead of reviewing the whole diff again 😅 I think this is the best option and also we shouldn't keep bikeshedding this issue. |
|
Oh yeah, sorry 'bout the unannounced force push – I was in my regular work projects workflow where I constantly rebase to keep the history tight. 😬 So, if everyone is fine with the current solution: |
This comment has been minimized.
This comment has been minimized.
|
🙈 you're right @mschilli87 |
misc/userscripts/qute-pass
Outdated
| argument_parser.add_argument('url', nargs='?', default=os.getenv('QUTE_URL')) | ||
| argument_parser.add_argument('--password-store', '-p', | ||
| default=os.getenv('PASSWORD_STORE_DIR', default=os.path.expanduser('~/.password-store')), | ||
| help='Path to your pass password-store') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add (only used in pass-mode) to the help text?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch, added. 👍
Co-Authored-By: Jan Holthuis <holthuis.jan@googlemail.com>
|
Build failed but, but this looks unrelated 👼 – should I rebase on master? |
|
Meh, flaky tests - feel free to just ignore them. |
|
Thank you! |
The new CLI-switch
--pass-executablemakes qute-pass compatible with the gopass password store (https://github.com/gopasspw/gopass). While gopass itself is mostly compatible with pass, it offers the possibility to mount multiple shared password stores. qute-pass way of just traversing PASSWORD_STORE_DIR won't help in that case.--
I've tried to keep backwards-compatibility with the old behaviour as much as possible. The method
find_pass_candidateswill now just branch out into two different modes depending on which password executable is used. In thepassway, the code stayed the same.Closes #5142