How To Install govendor on Debian 10

Learn how to install govendor on Debian 10 with this tutorial. govendor is Go vendor tool that works with the standard vendor file

Introduction

In this tutorial we learn how to install govendor on Debian 10.

What is govendor

govendor is:

govendor is a vendoring tool that fetches, annotates, and synchronizes dependencies for the Go programming language. It can be useful as a stand-alone tool even if it is not the primary vendoring tool. Inspection sub-commands such as “govendor list” and “govendor license” can be useful to find information on dependencies and their statuses. “govendor fetch” will update or add new dependencies directly from remotes. If you choose to not check in your dependency source code, use “govendor sync” to pull the correct revision into the vendor folder.

Frustrated by not being able to run “go test ./…” anymore? Run “govendor test +local” even if you do not use govendor elsewhere. Look into the different statuses that can be assigned to packages, they are useful. Still using godep or glock? Migrate them over including manifest file using “govendor migrate”.

There are three methods to install govendor on Debian 10. We can use apt-get, apt and aptitude. In the following sections we will describe each method. You can choose one of them.

Install govendor Using apt-get

Update apt database with apt-get using the following command.

sudo apt-get update

After updating apt database, We can install govendor using apt-get by running the following command:

sudo apt-get -y install govendor

Install govendor Using apt

Update apt database with apt using the following command.

sudo apt update

After updating apt database, We can install govendor using apt by running the following command:

sudo apt -y install govendor

Install govendor Using aptitude

If you want to follow this method, you might need to install aptitude first since aptitude is usually not installed by default on Debian. Update apt database with aptitude using the following command.

sudo aptitude update

After updating apt database, We can install govendor using aptitude by running the following command:

sudo aptitude -y install govendor

How To Uninstall govendor on Debian 10

To uninstall only the govendor package we can use the following command:

sudo apt-get remove govendor

Uninstall govendor And Its Dependencies

To uninstall govendor and its dependencies that are no longer needed by Debian 10, we can use the command below:

sudo apt-get -y autoremove govendor

Remove govendor Configurations and Data

To remove govendor configuration and data from Debian 10 we can use the following command:

sudo apt-get -y purge govendor

Remove govendor configuration, data, and all of its dependencies

We can use the following command to remove govendor configurations, data and all of its dependencies, we can use the following command:

sudo apt-get -y autoremove --purge govendor

Dependencies

govendor have the following dependencies:

References

Summary

In this tutorial we learn how to install govendor package on Debian 10 using different package management tools: apt, apt-get and aptitude.