Skip to content
master
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
bin
 
 
img
 
 
lib
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

README.md

Twittodon

Search specific tweet and post toot to mastodon

wercker status Coverage Status

Features

  • Search specific tweet
  • Post toot to specific Mastodon instance
  • When tweet contains media (e.g. photo, animation gif), download from twitter and upload mastodon
  • Supports Deploy to Heroku (1 click deploy 😤)

Deploy

Getting Started

Read GETTING_STARTED.md

Rake tasks

You can run rake tasks on heroku via heroku cli

e.g.

  • Local: bundle exec rake perform
  • Heroku: heroku run rake perform

rake perform

Search specific tweet and post toot to mastodon

Parameters

rake since_id:display

Display all since_ids (since_id is cache for each search query)

Example

$ bundle exec rake since_id:display
query='from:sue445 -RT #precure', since_id=869561044380786688
query='from:sue445 -RT', since_id=869557396930088966

rake since_id:delete

Delete specific since_id

Parameters

  • QUERY : Twitter search query

Example

$ QUERY="from:sue445 -RT" bundle exec rake since_id:delete
Deleted query='from:sue445 -RT', since_id=869557396930088966

rake since_id:delete_all

Delete all since_ids

Example

$ bundle exec rake since_id:delete_all
Deleted query='from:sue445 -RT', since_id=869557396930088966
Deleted query='from:sue445 -RT #precure', since_id=869561044380786688

Requirements

  • Ruby
  • Redis

Development

Setup

bundle install
cp .env.example .env
vi .env

Environment variables

All available environment variables are here

Heroku

Setup

heroku addons:add heroku-redis
heroku addons:add papertrail
heroku addons:add rollbar
heroku addons:add scheduler

heroku config:add ENVIRONMENT=production
heroku config:add TWITTER_CONSUMER_KEY=XXXXXXXXXXXXXX
heroku config:add TWITTER_CONSUMER_SECRET=XXXXXXXXXXXXXX
heroku config:add TWITTER_ACCESS_TOKEN=XXXXXXXXXXXXXX
heroku config:add TWITTER_ACCESS_TOKEN_SECRET=XXXXXXXXXXXXXX
heroku config:add MASTODON_URL=https://mastodon.example.com
heroku config:add MASTODON_ACCESS_TOKEN=XXXXXXXXXXXXXX

About

Search specific tweet and post toot to mastodon

Topics

Resources

License

Releases

No releases published

Languages

You can’t perform that action at this time.