The error “add-apt-repository: command not found” occurs because the add-apt-repository
command is part of the software-properties-common
package, which is not installed by default on some Ubuntu distributions.
To resolve the error, you need to install the software-properties-common
package by running the following command:
sudo apt-get update
sudo apt-get install software-properties-common
After installing the package, the add-apt-repository
command should be available and you should be able to add new repositories to your system.
Note that if you encounter any other errors while using the add-apt-repository
command, you may need to check that your system is fully updated and that you have the necessary permissions to modify the repository list.