For all those people who like to use Twitter in console/terminal rather than Graphical User Interface can now access their twitter account right from the Linux Console. Yes you heard it right. You can now access your Twitter account using a Linux Command-line Twitter Client called Rainbow Stream.
What is Rainbow Stream
Rainbow Stream is a free and open source Twitter-client for Linux command-line, released under MIT License. It is capable of showing Realtime tweetstream, compose a tweet, search, favorite,…..etc. Rainbow Stream gives a real-fun right into your Linux terminal. It is also capable of showing twitter images directly on terminal.
It is written in Python and built on top of Twitter API and Python Twitter Tool. To run this application in your console you must have installed python and pip version 2.7.x or 3.x.
Features of RainbowStream
- Free and open source Twitter-client for Linux command-line.
- Capable of rendering twitter image in Terminal.
- Support Proxy.
- Interactive Mode supported.
- Theme Customization well implemented.
- Capable of showing Real-time Twitter stream.
- You can tweet, search, favorite tweets right from your terminal.
Installation of Rainbow Stream Twitter Client in Linux
In most of the today’s Linux distribution, python should already be installed on your system. You may check the version of Python installed as:
$ python --version
Next, install python-pip package using following commands as per your Linux distributions.
# apt-get install python-pip [on Debian alike systems] # yum install python-pip [on CentOS alike systems]
Note: Use ‘dnf‘ in place of yum, if you are on Fedora 22.
Check version of installed pip.
$ pip --version pip 1.5.4 from /usr/lib/python2.7/dist-packages (python 2.7)
Now its time to install rainbow stream twitter client.
# pip install rainbowstream [For Python 2.7.x version] # pip3 install rainbowstream [For Python 3.x version]
After successful installation you should get the below message in your terminal.
You may like to get help on rainbowstream.
$ rainbowstream -h OR $ rainbowstream --h
Rainbow Stream Twitter Client Usage
1. First you need to connect and authorize application on twitter site using your twitter account.
Note: You must have a twitter account, if you don’t create one.
2. Now type 'rainbowstream'
in your Linux terminal, as user.
$ rainbowstream
It will open a tab in your default HTTP web browser, login and you will get a pin. If you have already logged into your account the page should be showing PIN. If you have configured more than one Twitter account in your HTTP web browser, consider trying logging out of other account and login to the account you want to connect.
3. Copy the PIN from HTTP web Browser into your terminal and hit return key.
It will take a few seconds and you should get your twitter_user_name in your Linux prompt.
Notice your Twitter stream, you should see tweets by those whom you follow.
4. To display tweet’s images directly in your Terminal, you can do:
twitter: rainbowstream -iot
5. To display current twitter Trend.
twitter: trend
6. To see current twitter trend specifically country-wise, for example India (IN).
twitter: trend IN
Note: Here IN is for India. If you want to see Current Trend for US, or any other country, you may do so.
7. To see your twitter Home and Followers.
twitter: home twitter: ls fl
8. T see list of all your friends, people whom you are following.
twitter: ls fr
Here is the list of commands you can run to handle your twitter tweets and feeds from your Linux terminal.
Command | What it does |
h | Help |
p | Pause Twitter Stream for the client in your Terminal |
r | Resume Twitter Stream, which was Paused Earlier |
c | Clear the Linux Console |
v | Version Information of Twitter Client |
q | Quit Rainbow Stream |
theme | List all the available Themes |
theme Name_of_Theme |
Apply the Theme e.g., theme monaki will apply monaki Theme |
notification | See your Twitter Notification |
whois @Avishek_1210 | It will show Profile of @Avishek_1210 |
mentions | It will show mentions timeline. |
view @Avishek_1210 | Show timeline of @Avishek_1210 |
s string |
It will search for word ‘string’. You may use it with/without HashTag |
t I Love #Tecmint | It will Print I Love #Tecmint on Twitter |
inbox | Show your Inbox Messages |
fl @Avishek_1210 | Follow @Avishek_1210 |
ufl @Avishek_1210 | Unfollow @Avishek_1210 |
block @Avishek_1210 | Block @Avishek_1210 |
unblock @Avishek_1210 | Unblock @Avishek_1210 |
report @Avishek_1210 | Report @Avishek_1210 as SPAM Account |
List home | Show timeline of List |
You can also perform Mathematical Calculation, which is a feature of Python simply as:
[@Avishek_1210]: 2*3 6 [@Avishek_1210]: 2**3 8 [@Avishek_1210]: 2+3 5 [@Avishek_1210]: 3-2 1 [@Avishek_1210]: 4/3 1
You can use cal command simply as if you would have done in terminal.
[@Avishek_1210]: cal August 2015 Su Mo Tu We Th Fr Sa 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
Want to have some fun with this application? Try and see what happens:
random_rainbow('Your Text Here') OR order_rainbow('Your Text Here')
So guys how is the application? Do you like this? If you are a Linux-er and used to Twitter, this application is for you. It is easy-to-setup and easy-to-use. Though I don’t use twitter very often but this application is really a rainbow and interesting and who knows I start using Twitter as much as Facebook, just because of interest in this command-line Twitter-client. This application is worth giving a try. Let your voice be audible. Provide us with your valuable feedback in the comments below. Like and share us and help us get spread.
I do not have XP. It shows me error when installing rainbow stream. I thought I did not need graphical environment.
Most impressive! Thank you for the how-to. I got it installed on my Raspberry Pi. Just had to install the Python-dev package first.
Welcome Raj W.
Keep connected for more such posts.