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

CLI: Clip or Show the best (only) match when not providing the full entry path #4270

Closed
lerignoux opened this issue Feb 1, 2020 · 1 comment · Fixed by #4489
Closed

CLI: Clip or Show the best (only) match when not providing the full entry path #4270

lerignoux opened this issue Feb 1, 2020 · 1 comment · Fixed by #4489

Comments

@lerignoux
Copy link
Contributor

Summary

Currently in order to fetch a password one needs to know its full path or do a locate preliminarily
It would be more efficient to add an option to clip or show the only entry found if only one entry match the input search term (or regex ?)

Desired Behavior

I would like for instance if I have an entry /group/toto unique (there are no other toto entry anywhere) to be able to clip it directly without knowing in what group it is located

Possible Solution

I would like to add a -best option to clip and show that would:
if provided we will locate the entries matching the given input.

  • if multiple are found we display an error and the list of entries matching (~ similar to locate)
  • if none are found we display an error (~ similar to locate)
  • if only one entry is found we clip or show it depending of the command.

I also saw there was a suggestion to add tab autocompletion on keys, this could be another way

Context

I only use the command line to copy passwords and doing a locate + clip is a bit long.

@lerignoux
Copy link
Contributor Author

lerignoux commented Feb 1, 2020

I started to check how to implement it myself, after building my solution though I cannot seem to run it for testing purposes.
I thought the executable generated in release/build-release/src would contain the newly built executable but my additional option does not seem to exists.
cf Diff

@droidmonkey droidmonkey changed the title Clip or Show the best (only) match when not providing the full entry path CLI: Clip or Show the best (only) match when not providing the full entry path Feb 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants