Introducing Betty, the Siri for the Linux Terminal

Betty is like Siri or Google Now for the command line. Well, sort of. The tool translates plain English into commands: it displays the command it runs and obviously, the command output, in the terminal. It can even speak the command output.

Screenshot from 2014-05-16 14:31:26

Betty’s mission is, according to its GitHub page, to “provide a way to use computers through natural language input“:

“Specifically, the benefit is being able to do things on your computer without leaving the command line or screwing around on the internet trying to find the right command. Betty just works“.

For example, if you can’t remember the exact compress and uncompress commands, you can simply ask Betty to do it:

betty uncompress archive.tar.gz

Of course, the commands supported by Betty at this time is pretty limited since the tool is under two weeks old, but it should improve quite fast since it’s not that hard to add new commands (and there are 17 contributors already).

Betty 0.1.5 supports a wide variety of commands, such as:

count (number of characters in a file, number of words in a directory, etc.);

config (change your name);

datetime (current time, date, etc.);

Find (find in files);

Internet / web queries (download some file, find out what’s the weather like, etc.);

file / directory operations (compress/uncompress files, show file size, change permissions, etc.);


user commands (what’s my username, real name, ip address, who else is logged in, etc.);

control iTunes and Spotify;

and much more.

A complete list of supported commands is available @ GitHub (under Documentation).

How to install Betty:

1. Install Ruby. In Ubuntu, install it using the following command:

sudo apt-get install ruby

2. Install git and download the latest Betty using the following commands:

sudo apt-get install git

3. And finally, you’ll have to add the path to the “betty/main.rb” file as an alias for “betty” in your ~/.bashrc file. Do this automatically (assuming you’ve downloaded Betty in your home folder!) by using the following commands:

echo “alias betty=\”~/betty/main.rb\”” >> ~/.bashrc
source ~/.bashrc


via Betty Is Like Siri Or Google Now For The Command Line (Translates Plain English Into Commands) | Best of Ubuntu.

Get the Most from Your Terminal with Tabs and Other Customizations

Modern Linux distributions try to shield users from the complexities of the command-line, but there are times when using a terminal is absolutely necessary. On Ubuntu, the default terminal is the GNOME terminal (“gnome-terminal“). To start it, tap the “Super” key (which is probably the Windows key on your keyboard), type “terminal” and then click on the Terminal icon.

The word terminal comes from a previous era in computing when the connection from a computer ended (terminated) at a character-based workstation. This concept itself comes from the field of electronics where a terminal is the the end of a line where signals are either transmitted or received. Today, the terminal program is a software equivalent of those character-based workstations.

For quick one-line commands, or a quick bit of system configuration, the default terminal settings are more than adequate; however, if you spend any length of time using the terminal, you may find that you want to customize it to better fit your needs.

The simplest customization is to change the dimensions of the terminal window. By default, the terminal window has twenty-four rows with each being eighty characters wide. You can change the size by dragging any of the edges or corners. This can be a bit haphazard, so the terminal program also offers some presets. Click Terminal on the menu bar and choose between 80×24 (the default), 80×43 (a long version of the default), 132×24 (wide) and 132×43 (wide and long).

If you need another terminal session, you can start one from the launcher, or you can right-click inside the terminal window and click “Open Terminal”. If you use the second method, then the current working directory is preserved. If you have several terminal windows open then you may find that your screen is getting a little cluttered. The solution is to open terminal tabs. To open a tab, right-click inside the terminal window and click “Open Tab”. The tabs appear at the top of the window, and the title of the tabs shows the current prompt: A combination of the username, the machine name and the current directory. Tabs can be closed by clicking on the X, by using “Close Tab” from the context menu or by exiting the shell with CTRL-D.

The terminal program also has the concept of a profile. This allows you to set different preferences and remember them in a profile. Each terminal session can use a different profile. To create a profile, select “New Profile …” under the ”’File” menu. To edit a profile’s preferences use ”Profile Preferences” under the Edit menu or right-click and select “Profile Preferences” under the Profiles sub-menu.

Among the preferences are the ability to change the default font and alter the amount of scroll history that is retained. You can also set the background color and make the background semi-transparent!

If you like the tabs on the Ubuntu terminal, then you might also be interested in another terminal program called Terminator. Like the default terminal program, it allows you to open multiple sessions, but rather than using tabs, it allows the terminal windows to be split horizontally or vertically. By splitting the window multiple times, several different terminal sessions can be started.

To install it, use the Ubuntu Software Center or type the following command in a terminal window:

sudo apt-get install terminator

To start the program, tap the “Super” key, type “terminator” and click the Terminator icon. To start another session, right-click inside the terminator window and click “Split Horizontally” or “Split Vertically”. Repeat the process to split another pane and so on.

via Get the Most from Your Terminal with Tabs and Other Customizations.