FriendRetweet is a command-line PHP script that allows you to automatically retweet the most popular tweets of the people youâ€™re following. Each time it is run, the app will scan your users home timeline and find the most popular tweet since the last time it was run. It will then retweet that tweet.
Download the script here: https://github.com/Decidedly/FriendRetweet
- Create a Twitter app for yourself at https://apps.twitter.com. Make sure you create an access token and set your permissions to read-write as well.
php composer install
cp config/example.config config/username.config
- Configure the app as follows:
Config Key Description
Your Twitter consumer key
Your Twitter consumer secret
Your Twitter access token
Your Twitter access token secret
Your numeric Twitter User id.
A path to the file where your userâ€™s data will be stored. These files donâ€™t generally get very big.
A value of true causes native tweets, a values of false causes us to simply tweet the same text as the source tweet.
Running the App
From the command-line, type this:
php FriendRetweet.php --config configs/username.config