Changing the Default Terminal to Terminator on Ubuntu
Terminator is a powerful tool for developers, allowing you to manage multiple terminal sessions in a single window. Features like splitting panes, tabs, and simultaneous input can significantly boost your productivity.
Step 1: Install Terminator
First, install Terminator using the apt
package manager.
sudo apt update
sudo apt install terminator -y
The -y
option automatically answers 'yes' to any prompts during the installation process, streamlining the setup.
Step 2: Set as the System Default
Ubuntu uses a utility called update-alternatives
to manage default applications. We'll use this tool to change the default terminal emulator (x-terminal-emulator
) to Terminator.
Run the Configuration Command
Enter the following command in your terminal. A list of available terminals will appear.
sudo update-alternatives --config x-terminal-emulator
Select Terminator
From the resulting list, enter the selection number corresponding to terminator and press Enter.
There are 2 choices for the alternative x-terminal-emulator (providing /usr/bin/x-terminal-emulator).
Selection Path Priority Status
------------------------------------------------------------
* 0 /usr/bin/gnome-terminal.wrapper 40 auto mode
1 /usr/bin/gnome-terminal.wrapper 40 manual mode
2 /usr/bin/terminator 50 manual mode
Press <enter> to keep the current choice[*], or type selection number: 2
In the example above, you would enter 2
.
Step 3: Verify the Changes
The easiest way to confirm that the changes have been applied is to use the default shortcut to open a terminal: Ctrl+Alt+T
. If Terminator launches instead of the default GNOME Terminal, you've succeeded.
You can also right-click in your file explorer and select 'Open in Terminal' to see if Terminator opens.
Step 4: Integrate with VS Code
You can also set Terminator as the integrated terminal in Visual Studio Code.
- Open VS Code.
- Press
Ctrl+Shift+P
to open the Command Palette and search forOpen User Settings (JSON)
to open yoursettings.json
file. - Add the following JSON configuration. This sets the default terminal profile in VS Code to Terminator.
{
// ...your other settings
"terminal.integrated.profiles.linux": {
"terminator": {
"path": "terminator",
"icon": "terminal-multiple"
}
},
"terminal.integrated.defaultProfile.linux": "terminator"
}
Now, when you open a new terminal in VS Code (Ctrl+ `), Terminator will launch.
Reverting
If you ever want to switch back to the original GNOME Terminal, simply run the update-alternatives
command again and select the number corresponding to gnome-terminal.wrapper
.
sudo update-alternatives --config x-terminal-emulator
With this guide, you can switch your development environment's terminal to the more efficient Terminator and enhance your productivity.
Comments
Post a Comment