voronianski / node-tweet-cli

Start making tweets from your bash, zsh, whatever!
http://pixelhunter.me/post/66092531636/tweeting-command-line-application-with-flatiron-js
81 stars 17 forks source link

Stream timeline #9

Closed victorperin closed 9 years ago

victorperin commented 9 years ago

Is there a way to start streaming the timeline? I'll try to find a way and post a pull request, but if someone knows how to do this it could be faster.

voronianski commented 9 years ago

@victorperin it's possible to stream keyword for now - https://github.com/voronianski/node-tweet-cli#tweet-stream--options

Pull request for timeline is welcome!

victorperin commented 9 years ago

What do you think about that idea?

Also, I noticed that in line 69 of api.js:

process.stderr.write('error parsing:'+str+'\n');

is the problem of causing an annoying message. Can we remove it? it's already on a try-catch so, it'll just not show this message.

or put it:

if(str!=''){
   process.stderr.write('error parsing:'+str+'\n');
}
voronianski commented 9 years ago

@victorperin thanks for PR!

Also, I noticed that in line 69 of api.js:

I think that friendly message in console on parse error is fine (https://github.com/voronianski/node-tweet-cli/blob/master/src/common/api.js#L68) though I think it will be better to use cli and common error handler (see - https://github.com/voronianski/node-tweet-cli/blob/master/src/common/errors.js#L7) like in the commands.

/cc @rikkertkoppes

rikkertkoppes commented 9 years ago

Nice addition. Maybe accept an optional user handle to stream other user's timelines?

voronianski commented 9 years ago

I'll close this for now. I've made some huge styling switch https://github.com/voronianski/node-tweet-cli/commit/25e7159a383678e0cd0d1e43acb1e0796aebad37 so make sure your forks are up to date ;)