Code Monkey home page Code Monkey logo

birdknife's People

Contributors

vanita5 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

birdknife's Issues

Equals sign parsing...

Posting: asdf=asd?asd

Result: asdf='asd?asd'

TODO:
birdknife-parser needs a functions to preparse and postparse.
Preparse for Vorpal. This includes encoding chars (' and =)
Postparse to decode chars.

Improve events

  • Displaying: Always show event information like a status text instead of IDs
  • Add missing events:
    • blocked
    • retweeted_retweet
    • favorited_retweet
    • ...
  • Events should trigger notifications

Delete command and retweeting your own tweets

In birdknife the /delete command either deletes your tweet or tries to removes the retweet if it's from another user.
Now that you can retweet your own tweets, what do we do with a retweet of your own tweet?

Introduce something like /unretweet?

Display and send media alt text

Upload media with alt text example:

T.post('media/upload', { media_data: b64content }, function (err, data, response) {
  // now we can assign alt text to the media, for use by screen readers and
  // other text-based presentations and interpreters
  var mediaIdStr = data.media_id_string
  var altText = "Small flowers in a planter on a sunny balcony, blossoming."
  var meta_params = { media_id: mediaIdStr, alt_text: { text: altText } }

  T.post('media/metadata/create', meta_params, function (err, data, response) {
    if (!err) {
      // now we can reference the media and post a tweet (media will attach to the tweet)
      var params = { status: 'loving life #nofilter', media_ids: [mediaIdStr] }

      T.post('statuses/update', params, function (err, data, response) {
        console.log(data)
      })
    }
  })
})

Update status with media

Uploading media is documented here (Twitter).
There is a example on how to upload media with twit:

//
// post a tweet with media
//
var b64content = fs.readFileSync('/path/to/img', { encoding: 'base64' })

// first we must post the media to Twitter
T.post('media/upload', { media_data: b64content }, function (err, data, response) {

  // now we can reference the media and post a tweet (media will attach to the tweet)
  var mediaIdStr = data.media_id_string
  var params = { status: 'loving life #nofilter', media_ids: [mediaIdStr] }

  T.post('statuses/update', params, function (err, data, response) {
    console.log(data)
  })
})

//
// post media via the chunked media upload API.
// You can then use POST statuses/update to post a tweet with the media attached as in the example above using `media_id_string`.
// Note: You can also do this yourself manually using T.post() calls if you want more fine-grained
// control over the streaming. Example: https://github.com/ttezel/twit/blob/master/tests/rest_chunked_upload.js#L20
//
var filePath = '/absolute/path/to/file.mp4'
T.postMediaChunked({ file_path: filePath }, function (err, data, response) {
  console.log(data)
})

Maybe we can implement filesystem autcompletion.

Note: Remaining character count should respect the media url length

Unhandled rejection TypeError: Cannot read property 'user_mentions' of undefined

Occured while faving a status. Maybe due to a slow internet connection

Unhandled rejection TypeError: Cannot read property 'user_mentions' of undefined at Object.module.exports.autoBoldStatusEntities (/usr/lib/node_modules/birdknife/libs/birdknife-text.js:53:32) at /usr/lib/node_modules/birdknife/libs/TwitterAPI.js:347:49 at tryCatcher (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/util.js:16:23) at Promise._settlePromiseFromHandler (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/promise.js:503:31) at Promise._settlePromise (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/promise.js:560:18) at Promise._settlePromise0 (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/promise.js:605:10) at Promise._settlePromises (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/promise.js:684:18) at Async._drainQueue (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/async.js:126:16) at Async._drainQueues (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/async.js:136:10) at Immediate.Async.drainQueues [as _onImmediate] (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/async.js:16:14) at processImmediate [as _immediateCallback] (timers.js:383:17)

Notifications

Implement system notifications. A cross platform library with Growl fallback is available: node-notifier

Notifications should be originate on mentions and all events.

Autocompletion

Implement autocompletion for at least usernames and hashtags.

Version information

Display birdknife version on start-up.
Notify or display update information if a new version is available.

Persistent cache

Implement a persistent cache for at least usernames and hashtags.
#12 (Autocompletion) depends on this.

Timestamps

For now the timeline is being displayed without time information.

We should either display status timestamps or a time seperation marker every x minutes. This should be a preference.

Pipe parsing

Trying to post status with pipe (|) breaks the command.

Display full DMs

DMs received from the stream seem to contain the full text.
The REST API only returns a limited number of characters per message and hast a t.co link.

Edit preferences "in-app"

For now one has to edit the .birdknife.config file.

Provide a command to display and set preferences.

Preferences

The user should be able to configure the following preferences:

  • Locations (see #3)
  • ...

Preferences must be readable and writeable inside the CLI.
Are we gonna use a config file (allows easy external preference editing) or some kind of database?

Birdknife logo

The current ASCII art logo seen in the README is too large and should be made more beautiful.

Better ASCII art or a "real" logo?

Quotes

Implement Twitter's quote feature to comment tweets.

To quote a tweet we have to append the status with the quoted tweet's URL.

Note: Remaining character count should respect the tweet url length

Add option to reply to status author only

At the moment, /reply appends all mentioned users to your reply.
Add option to reply to status author only.

This is important, as I just unintentionally spammed @herrurbach's inbox!

Mutes

Implement

  • mutes/users/create
  • mutes/users/destroy

config.json location

Currently the config.json containing consumer keys and access token are located inside the node package.
This is inconvenient as one has to reauthenticate everytime birdknife is being updated. Especially if we plan to use the config.json for additionally preferences (#11).

The file should initially be copied to the user's home directory and accessed from there.

navigation / exploration

hey!

i tried birdknife for the first time today, and i really like it, but it seems like it could use better navigation (or documentation, if i'm just missing key features).

for instance, it prints out timestamps every 5 minutes, but doesn't print any tweets that occurred between them, which seems pretty counter-intuitive (either it doesn't need to print timestamp lines, or it should print the new tweets? i had someone i'm following tweet once, unrelated to me, and once, mentioning me, and neither were printed by birdknife without using /again). notifications is set to true (confirmed via /preferences).

also, i find myself using /again a lot and wishing that it had some options for sifting, like relatively counted ranges (show me from the fifth to last to the eight to last).

a way to show a list of people you're following would also be great.

additionally, /thread failed fairly spectacularly the one time i tried it; it turns out that the example i found had a branched structure; birdknife incompletely traversed one branch and didn't visit the other. not sure how to handle cases like these. oh, and each /thread gave the tweets new IDs, so the same tweets are locally stored under several names.

i'm sorry for packing so much into one issue, but i really like this project and would like to contribute some!

Prevent unintended status updates

  • If a user has a typo in a command, the input is treated as a status update.
  • Accidentally pasting text containing newlines into the CLI posts multiple status update.

TODO

  • Inputs not recognized as a command by vorpal but starting with a / should trigger a prompt asking the user if they really want to post this and/or provide similar command suggestions
  • Detect pasted text or limit status updating speed like TTYtter does

Logged in as undefined

If no internet connection is available, birdknife says Logged in as undefined and throws errors afterwards.

Blocks

Implement

  • blocks/create
  • blocks/destroy

Update status with location

Parameter:

  • lat
  • long

Alternative:

  • place_id

Is it necessary to set display_coordinates == true?

This feature probably depends on user preferences which have to be implemented first.
A user must be able to enable or disable adding their location to status updates.

The location could be provided either manually (latitude, longitude) or maybe with a module like this

Retweeted quotes

For retweeted quotes, the quoted tweet is not being displayed.
The original status of the retweet has to be parsed.

Unhandled rejection TypeError: result.data.reverse is not a function

Occured while executing /again <screenname>. Maybe due to a slow internet connection.

Unhandled rejection TypeError: result.data.reverse is not a function at /usr/lib/node_modules/birdknife/libs/TwitterAPI.js:130:29 at tryCatcher (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/util.js:16:23) at Promise._settlePromiseFromHandler (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/promise.js:503:31) at Promise._settlePromise (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/promise.js:560:18) at Promise._settlePromise0 (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/promise.js:605:10) at Promise._settlePromises (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/promise.js:684:18) at Async._drainQueue (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/async.js:126:16) at Async._drainQueues (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/async.js:136:10) at Immediate.Async.drainQueues [as _onImmediate] (/usr/lib/node_modules/birdknife/node_modules/bluebird/js/release/async.js:16:14) at processImmediate [as _immediateCallback] (timers.js:383:17)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.