elan command not found

In this troubleshooting guide we learn how to fix elan command not found error message

Introduction

When you run more command in linux terminal / console, you get the following error message

elan: command not found

or when using sudo you get the following error message

sudo: elan: command not found

Solutions to elan: command not found

How To Fix elan: command not found in Ubuntu / Debian / Kali Linux / Raspbian

In Ubuntu elan is provided by elan package.

elan is:

elan is a small tool for managing your installations of the Lean theorem prover. It places lean and leanpkg binaries in your PATH that automatically select and, if necessary, download the Lean version described in the lean_version field of your project’s leanpkg.toml. You can also install, select, run, and uninstall Lean versions manually using the commands of the elan executable.

To fix this problem, we can install more using the command below.

sudo apt-get -y install elan

This command might take some time to finish depending on your machine internet connection.

You can also use apt command to install elan.

sudo apt -y install elan

Or if you have aptitude installed you can use the following command.

sudo aptitude install elan

Summary

In this tutorial we learn how to fix elan command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.