henrycatalinismith / ppl

The command line address book
http://henry.catalinismith.com/ppl/
Other
300 stars 18 forks source link

post bug? #11

Closed rlp10 closed 11 years ago

rlp10 commented 11 years ago

I'm running people on ubuntu 10.04 with ruby 1.9.3p327.

All the commands seem to work properly, except the 'post' command.

> ppl post me "1 Testing Road"
> ppl post me
>

Shouldn't that print back my postal address, like the other commands?

axelGschaider commented 11 years ago

completely offtopic: thanks. Now I figured out what "ppl" stands for :)

henrycatalinismith commented 11 years ago

Please don't bother following these instructions. I misread the original question as a potential bug instead of incorrect usage and as a result this entire comment is worthless. Sorry.

Hi there!

Glad to hear you've at least had some luck! But you're right, ppl post me should be printing the postal address of that contact. I have a few questions whose answers would help me narrow down the cause of the problem:

henrycatalinismith commented 11 years ago

Wait a second, I've been a bit careless here and failed to properly read your example code.

That usage of ppl post is incorrect I'm afraid. It doesn't work in quite the same way as other commands such as ppl email because postal addresses are quite complex beasts made up of several distinct parts. As such, you have to tell it which part of the address you're giving it. So instead of what's in your example, you'd do the following:

ppl post me --street "1 Testing Road"

And then you'd see some output from ppl post me. See the documentation for ppl post for more details.

In order to help avoid this confusion in future, I'm going to alter the behaviour of the command. Providing a string such as "1 Testing Road" without an option flag such as --street indicating what the string means is incorrect usage and users ought to be notified of the error.

rlp10 commented 11 years ago

Thanks very much for the clarification!