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

Search only within email #48

Closed
niklaas opened this issue Sep 20, 2014 · 4 comments
Closed

Search only within email #48

niklaas opened this issue Sep 20, 2014 · 4 comments

Comments

@niklaas
Copy link

niklaas commented Sep 20, 2014

First, great program! I love it. Second, could it be that only the email addresses are searched when I am querying the program through mutt? This is a bit enoying when people are using nicknames and I can't remember them -- and actually an address book should turn in and tell me the right email address. :-)

@henrycatalinismith
Copy link
Owner

Sounds doable! Let me quickly check I've understood your request.

Current Behaviour

A search for example returns results if either the contact's email or their name matches.

$ ppl mutt example
test@example.org    John Doe
other@another.com  example user
Desired Behaviour

The same search only returns results when the email address matches.

$ ppl mutt --emails-only example
test@example.org    John Doe

This is definitely a tweak I can make for you. For the sake of backwards compatibility, I'll add it under a --emails-only flag on the ppl mutt command though. Don't wanna break things for people! :)

@niklaas
Copy link
Author

niklaas commented Sep 22, 2014

Thank your for your quick reply. Sorry, I think I was mixing something up because the search is case-sensitive and I did not know that. So I guess this turns into two ›issues‹:

  1. The .vcffile name is not searched. (which is the original issue)
  2. Why is the search case-sensitive?

A contact's name and its email is searched but not the name of the .vcf file. Sometimes I am using this for a nickname for example mum.vcf or dad.vcf. So it would be great if the search also considers file names. (Of course, I can also change my behaviour in naming the files.)

Have a look at this example for clarification:

# niklaas at len-x61s in ~ [16:31:55]
$ ppl ls | grep username
username:              FirstName Surname            <firstmailpart@domainpart.com>

If I query for username I get no results. (Maybe this is intended but I would find it handy.)

If I query for surname I get no results. I think this is not really useful.

If I query for Surname I get a result (of course).

@the-reverend
Copy link

you can get a case insensitive search with ppl grep -i username

@henrycatalinismith
Copy link
Owner

Wow oops, I've really let some old issues rot here. Gonna close this one as it looks like that workaround is okay!

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

No branches or pull requests

3 participants