What is Snap in Ubuntu?
Snap in Ubuntu is a software package manager similar to the apt manager which is developed by Canonical. This package manager allows developers to package their applications and all the related dependencies into he single container, which makes it easy to distribute and also install software over different Linux distributions. Snap packages are created to be self-contained with all the essential libraries and all the dependencies bundled together making sure that the application runs consistently over the Linux systems.
Installation of Snap in Ubuntu
Follow the below steps to install the Snap package manager in the Ubuntu Operating System without encountering any issue or error.
Step 1: First update the system with all the latest packages by using the apt package manager. Execute the below command in the terminal to update the system.
sudo apt update
Step 2: After updating the system, install the Snap daemon, which is the background service required for managing and running Snap packages.
sudo apt install snapd
Step 3: After installing the daemon, start and enable the Snap socket for communication between the system and the Snap daemon.
sudo systemctl enable --now snapd.socket
How to use update-alternatives
In the Ubuntu environment, adding NeoVim (nvim) to update-alternates while using Snap manager mainly involves the process of creating a symbolic link to the nvim executable in a directory listed in the system’s PATH. Snap packages are mainly isolated, so their binaries might not be automatically included in update-alternatives. To resolve this, we need to manually create a symbolic link from the nvim executable within the Snap package to the directory. In this article, we will see how we can add nvim to update-alternatives when using snap under Ubuntu.
Contact Us