Twitter has become an addicting, fun distraction for many of us. But since it’s mostly a text only media, why not tweet while you’re working in the Linux terminal? Score some geek points, and tweet the Linux geek’s way.
Twidge is a simple Twitter client for the Linux command line. There are other command line Twitter clients, but Twidge is simple to use and easy to install, where many others have not been updated since Twitter changed authorization, and therefore do not work. The Twidge project can be found here, at github.
The github wiki page has links to source, Debian and Arch Linux Packages. Choose whichever suits you, suited for whatever distro of Linux you happen to be running. We’ll be downloading the Debian package and installing it into Ubuntu. Here’s two ways to install Twidge.
Option 1: Add Repositories and Install Via Command Line
If you prefer, you can edit your repositories by opening up a Terminal and running:
$ sudo gedit /etc/apt/sources.list
The current repository you’ll have to add in your sources.list is for “squeeze” the current stable release. Copy it from here, if you dislike typing.
deb http://ftp.de.debian.org/debian squeeze main
Save this repository to your sources.list to be able to download Twidge. In order to install from the command line, run:
$ sudo apt-get update
$ sudo apt-get install twidge
Twidge will be ready to run. If you prefer to install in a more Windows-user friendly method by downloading the Debian package, read the next step.
Option 2: Download and Install the Debian Package
Assuming you’re using Ubuntu, you should find the links to the Debian packages on the Twidge wiki front page. As of this posting, the current version is “squeeze,” so navigate to that via the link below.
- Twidge wiki at github
Many different architectures are available. Most readers are probably i386 or amd64, although there’s a good chance most of you Linux geeks already know that. Download the appropriate architecture from any mirror that suits you.
Simply double-click the package to install.
Easy enough. Keep in mind that installing this way means you cannot pull updates from the repository, so if there’s a major update to Twidge, you’ll have to download and reinstall yourself.
Setting Up Twidge
Open up a terminal. We’ll need to run the setup for Twidge, which is a simple, if not obvious command.
$ twidge setup
Twidge runs an authorization, generating a secure link to a page where Twitter authorizes the application. Click it to open it in your browser.
Another easy step. Input your username and password, and click authorize.
You’ll get a PIN to copy into your terminal where it requests it.
Simply type or paste the key from your browser into your terminal window shown above.
And you’ve set up Twidge. In order to learn the ropes, don’t be afraid to read the man page:
$ man twidge
Sending That First Tweet
You can always update your Twitter with your newly authenticated client by using the following command:
$ twidge update
And then typing your 140 character update, as shown above.
Likewise, you can check your @replies with the command:
$ twidge lsreplies
And this is the command to see the most recent updates from your timeline:
$ twidge lsrecent
However, this is LINUX! Why waste time typing long commands when you can create aliases in your .bashrc file and save yourself the hassle?
$ sudo gedit ~/.bashrc
alias tweet=”twidge update”
alias replies=”twidge lsreplies”
alias recent=”twidge lsrecent”
Then save and close your gedit window. The aliases “tweet,” “replies,” and “recent” will do in place of the normal versions in the man page for Twidge.
Your tweets appear, easily sent via the command line. Enjoy using your Terminal to tell everybody about your breakfast!
- Download Twidge at github