Changing the Default Terminal to Terminator on Ubuntu

Image
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. ...

How to Install Python 3.12 on Ubuntu 22.04

python 3.12 installation

Ubuntu 22.04 ships with Python 3.10 by default. Since I needed Python 3.12 for newer features and compatibility, I installed it manually. Here’s how I safely set it up alongside the system Python.

Step 1: Update your system

sudo apt update
sudo apt upgrade -y

Step 2: Install Python 3.12 and tools

sudo apt install -y python3.12 python3.12-venv python3.12-setuptools python3.12-dev
  • python3.12: The main Python 3.12 interpreter.
  • python3.12-venv: Enables creation of virtual environments using python3.12 -m venv.
  • python3.12-setuptools: Provides tools to build and install Python packages (replacement for deprecated distutils).
  • python3.12-dev: Includes headers and libraries needed to build Python C extensions and compile native modules.

Step 3: Set python3 to point to Python 3.12

If your system still points to an older version, you can use update-alternatives to switch.

sudo update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.12 2
sudo update-alternatives --config python3

You will see a prompt like this:

There are 2 choices for the alternative python3 (providing /usr/bin/python3).

  Selection    Path                Priority   Status
------------------------------------------------------------
* 0            /usr/bin/python3.12   2        auto mode
  1            /usr/bin/python3.10   1        manual mode
  2            /usr/bin/python3.12   2        manual mode

Press <enter> to keep the current choice[*], or type selection number: 2

Step 4 (Optional): Set the python command to point to Python 3.12

sudo update-alternatives --install /usr/bin/python python /usr/bin/python3.12 2
sudo update-alternatives --config python

You will see a prompt like this:

There is 1 choice for the alternative python (providing /usr/bin/python).

  Selection    Path                Priority   Status
------------------------------------------------------------
* 0            /usr/bin/python3.12   2        auto mode
  1            /usr/bin/python3.10   1        manual mode
  2            /usr/bin/python3.12   2        manual mode

Press <enter> to keep the current choice[*], or type selection number: 2


Step 5: Verify your Python versions

python3 --version
Python 3.12.3
python --version
Python 3.12.3

Comments

Popular posts from this blog

Resolving Key Exchange Failure When Connecting with SecureCRT to OpenSSH

SecureCRT] How to Back Up and Restore SecureCRT Settings on Windows

How to Set Up Vaultwarden (Bitwarden) on Synology NAS (Best Free Alternative to LastPass)