How to Install Sublime Merge on Ubuntu 24.04, 22.04 or 20.04

This guide will demonstrate how to install Sublime Merge on Ubuntu 24.04, 22.04, or 20.04 LTS using the command-line terminal. It covers the installation process through the official Sublime APT repository for the latest version, easy future upgrades via CLI commands, and using Flatpak and Flathub for additional flexibility.

Sublime Merge is a cutting-edge tool designed to streamline the git process for developers. Its integration with Sublime Text provides a seamless experience for managing code repositories, making it a top choice for software development projects. The utility is renowned for its speed, allowing users to navigate through extensive codebases without lag. With Sublime Merge, developers gain access to a comprehensive suite of features aimed at simplifying version control, making it more accessible and less time-consuming.

Choosing Sublime Merge on Ubuntu comes with numerous benefits:

  • Effortless Navigation: Quickly move through repositories with unmatched speed.
  • Advanced Search Functions: Pinpoint commits, files, and even specific content within files effortlessly.
  • Syntax Highlighting: Enhance code readability with support for various languages.
  • Highly Customizable Interface: Adjust the application to fit your workflow.
  • Unified Command Palette: Execute commands without memorizing complex git syntax.
  • Integrated Merge Capabilities: Resolve code conflicts within the application for a smoother workflow.
  • Instant Blame View: Understand code changes at a glance.
  • Broad Compatibility: Available on Linux, macOS, and Windows, ensuring a consistent experience across platforms.

Moving forward, the detailed steps will guide you through the installation process.

Install Sublime Merge on Ubuntu via APT PPA

Update Ubuntu System Packages Before Sublime Merge Installation

Your journey begins with preparing your Ubuntu system. To do so, we must ensure that your system’s software packages are up-to-date. This is crucial for avoiding potential conflicts and ensuring compatibility with the new software.

Execute the following command in your terminal:

sudo apt update && sudo apt upgrade

Here, sudo apt update updates the package lists for upgrades for packages that need upgrading, while sudo apt upgrade installs the newest versions of all packages currently installed on your system.

Installation of Initial Packages for Sublime Merge

Sublime Merge requires specific dependencies for proper functioning. While most of these dependencies are likely already present on your Ubuntu system, confirming their presence is essential. The following command will ensure that these packages, software-properties-common, apt-transport-https, curl, and ca-certificates, are installed:

sudo apt install software-properties-common apt-transport-https curl ca-certificates -y

These packages serve various functions. For instance, curl is a tool for transferring data with URLs, and ca-certificates are necessary for establishing secure web connections.

Integrating the Sublime Merge PPA

Next, we move on to the installation of Sublime Merge. The Advanced Package Tool (APT) manager, a package handling utility, is the primary method for software management on Ubuntu. It’s a convenient and quick installation method. However, to use APT for installing Sublime Merge, you must first import a third-party repository or a “PPA.”

Start by importing the GPG key. A GPG, or GNU Privacy Guard key, is used for secure communication. You can import the GPG key with this command:

curl -fSsL https://download.sublimetext.com/sublimehq-pub.gpg | gpg --dearmor | sudo tee /usr/share/keyrings/sublime.gpg > /dev/null

Following the successful import of the GPG key, import the repository using the command:

echo 'deb [signed-by=/usr/share/keyrings/sublime.gpg] https://download.sublimetext.com/ apt/stable/' | sudo tee /etc/apt/sources.list.d/sublime-merge.list

This command appends the Sublime Merge repository address to your system’s software sources list.

Refresh APT Packages Index

Having added the new Sublime repository, we must instruct APT to re-synchronize the package index files from their sources via an APT update. This ensures that the latest changes from the Sublime repository are included:

sudo apt update

Install Sublime Merge on Ubuntu via APT Command

Finally, we are ready to install Sublime Merge. The following command will download and install the latest version of Sublime Merge from the recently added repository:

sudo apt install sublime-merge

Install Sublime Merge on Ubuntu via Flatpak and Flathub

This segment will explore an alternative route for setting up Sublime Merge on your Ubuntu system. This method involves using Flatpak, a versatile, universal package manager that delivers applications as self-contained packages known as flatpacks. Flatpak’s unique design isolates applications from the system, enhancing stability and security. It also offers the benefit of version consistency across different Linux distributions.

Note: If Flatpak isn’t already set up on your system, install it. Our comprehensive guide, “How to Install Flatpak on Ubuntu”, can walk you through the process.

Activating Flathub for Sublime Merge

Before we can tap into the power of Flatpak to install Sublime Merge, we must ensure that the Flathub repository is enabled on your system. Flathub is a primary hub for Flatpak applications, housing a vast collection of software that can be readily deployed on any Linux distribution.

To add the Flathub repository to your Flatpak configuration, use the following command in your terminal:

sudo flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo

This command checks if the Flathub repository exists in your Flatpak configuration. If not, it will add it, expanding your access to a broad spectrum of applications.

Install Sublime Merge on Ubuntu via Flatpak Command

With Flathub active and at your disposal, you can now move on to installing Sublime Merge. At this point, the flatpak install command will be your tool of choice. Execute the following command in your terminal:

flatpak install flathub com.sublimemerge.App -y

This command seeks Sublime Merge from the Flathub repository and initiates its installation.

Launch Sublime Merge on Ubuntu via GUI or CLI Methods

Once you’ve successfully installed Sublime Merge on your Ubuntu system using the APT or Flatpak method, launching the application and exploring its features is time.

CLI Commands to Launch Sublime Merge

APT Launch Method for Sublime Merge

The Sublime Merge installation via APT is closely linked to your system’s application directory. Hence, it can be called directly from the terminal using the following command:

sublime_merge

Flatpak Launch Method for Sublime Merge on Ubuntu

If you’ve installed Sublime Merge using Flatpak, you can launch the application from the terminal with the flatpak run command. This command signals Flatpak to initiate the specified application.

flatpak run com.sublimemerge.App

GUI Launch Method for Sublime Merge on Ubuntu

Launching Sublime Merge is a breeze for desktop users who prefer a graphical approach. Here’s the straightforward route to access Sublime Merge:

  1. Navigate to your system’s application menu. This is typically found at the lower left or upper left corner of your screen, denoted by an icon similar to a grid or a Ubuntu logo.
  2. Open the application menu to display a list of installed applications.
  3. Locate Sublime Merge in the list. You might have to scroll down or use the search bar at the top of the menu.
Sublime Merge application icon on Ubuntu LTS.
The Sublime Merge icon as seen on Ubuntu systems.

First-Time Tips with Sublime Merge on Ubuntu

In this section, we’ll delve into some valuable tips to help you streamline your experience with Sublime Merge on Ubuntu Linux. These are meant to assist you in leveraging the full potential of this software, be it through customizations, workflow enhancements, or shortcuts.

General Tips with Sublime Merge

Here are some general pointers to consider when using Sublime Merge:

  • Navigating the Interface: One of Sublime Merge’s strengths is its uncluttered, intuitive interface. Spend some time familiarizing yourself with the layout and where different functionalities are located.
  • Learning Git Basics: Sublime Merge provides a clean graphical interface for managing your Git repositories. However, a basic understanding of Git commands and principles can significantly enhance your tool usage.
  • Keyboard Shortcuts: Sublime Merge offers a number of keyboard shortcuts that can help expedite your Git operations. For instance, use Ctrl + P to switch between repositories, and Ctrl + Shift + P to access the command palette.

Customization Tips with Sublime Merge

Sublime Merge offers a range of customization options. Here are a few that you might find helpful:

  • Changing Themes: Sublime Merge comes with several built-in themes. You can switch between them by navigating to Preferences > Themes... in the application menu.
  • Custom Key Bindings: Sublime Merge allows you to customize your key bindings. This feature can be accessed through Preferences > Key Bindings.
  • Layout Customization: Sublime Merge also allows you to modify the application layout per your preference. You can adjust the layout by going to View > Layout.

Other Tips with Sublime Merge

Lastly, here are a few more recommendations to enhance your Sublime Merge experience:

  • Use Integrated Diff Tools: Sublime Merge has a built-in diff tool that lets you easily view changes between commits, branches, or the working directory.
  • Harness the Power of the Command Palette: The Command Palette (accessible via Ctrl+Shift+P) is a powerful feature of Sublime Merge. It allows you to perform nearly any action without taking your hands off the keyboard.
  • Take Advantage of Blame Feature: Sublime Merge provides an easy-to-use blame feature that helps you quickly determine who changed a line or section of code.

Remember, Sublime Merge is a potent tool. Its potential is unlocked when you familiarize yourself with its features and incorporate them into your workflow.

Default user interface of Sublime Merge on Ubuntu LTS.
A look at the default UI of Sublime Merge on Ubuntu.

Managing Sublime Merge on Ubuntu

Maintaining software efficiently is a crucial aspect of operating system management. This section is dedicated to ensuring your version of Sublime Merge is up-to-date and how to uninstall it if needed.

Update Sublime Merge

One of the keys to software performance and security is regular updates. Depending on your installation method, you can update Sublime Merge differently.

APT Update Command for Sublime Merge

The update process is straightforward if you use the Advanced Package Tool (APT) to install Sublime Merge. The APT is an easy-to-use tool for handling packages, and the command-line tool apt is a package management command-line utility used as an alternative to apt-get in Debian and Ubuntu Linux distributions. By using it, you can handle packages on your Ubuntu system. Use the following command:

sudo apt upgrade && sudo apt upgrade

This command will update Sublime Merge and all installed packages with updates available.

Flatpak Update Command for Sublime Merge

If you choose to use Flatpak for the installation, you can also update Sublime Merge using Flatpak’s built-in update command:

flatpak update

This command will seek updates for all installed Flatpak applications, including Sublime Merge.

Remove Sublime Merge

There may be times when you no longer require Sublime Merge on your Ubuntu Linux system. Here’s how to uninstall it.

APT Remove Command for Sublime Merge

If Sublime Merge was initially installed using APT, you can uninstall it using the following command:

sudo apt remove sublime-merge

The above command will remove Sublime Merge but leave behind configuration files and user data related to the application.

Additionally, to remove the PPA from your system, run the following command:

sudo rm /etc/apt/sources.list.d/sublime-merge.list

Flatpak Remove Command for Sublime Merge

If you installed Sublime Merge using Flatpak, use the following command to uninstall it:

flatpak uninstall --delete-data com.sublimemerge.App

Running this command will remove Sublime Merge and its associated data.

Final Thoughts

In wrapping up, this guide walked you through the steps to get Sublime Merge up and running on your Ubuntu system, be it 24.04, 22.04, or 20.04 LTS, using both the official Sublime APT repository and the alternative Flatpak method via Flathub. Sublime Merge, with its speed and efficiency in handling git operations, is a no-brainer for anyone looking to streamline their development workflow. Remember, keeping your software updated ensures you have access to the latest features and security enhancements. So, dive in, explore its powerful capabilities, and see how it can improve your coding projects. Here’s to making your git experience a breeze with Sublime Merge!

Leave a Comment


Your Mastodon Instance
Share to...