Installing deno is quite a simple process. Deno ships as a single executable with no dependencies.
There are two ways of installing deno on your machine:
- Using Binaries
- Using Commands
1. Using Binaries
We can download a release binary from the official deno releases page.
2. Using Commands
Below are the PowerShell and Shell commands that can be used for installing deno.
Shell (Mac, Linux):
$ curl -fsSL https://deno.land/x/install/install.sh | sh
$ iwr https://deno.land/x/install/install.ps1 -useb | iex
For the complete set of commands, please refer to https://deno.land
Deno installation test
To test your installation, run
deno --version. If this prints the Deno version to the console the installation was successful.
To update a previously installed version of Deno, you can run:
The above command will fetch the latest release from the official deno releases page and replace your current executable with it.
To install a specific version of deno:
deno upgrade --version 1.5.1
In the next section, we will run our first deno program.