Resolves #683
3.9 KiB
Installation
Task offers many installation methods. Check out the available methods below.
Package Managers
Homebrew
If you're on macOS or Linux and have Homebrew installed, getting Task is as simple as running:
brew install go-task/tap/go-task
Snap
Task is available in Snapcraft, but keep in mind that your Linux distribution should allow classic confinement for Snaps to Task work right:
sudo snap install task --classic
Chocolatey
If you're on Windows and have Chocolatey installed, getting Task is as simple as running:
choco install go-task
Scoop
If you're on Windows and have Scoop installed, use extras
bucket
to install Task like:
scoop bucket add extras
scoop install task
This installation method is community owned. After a new release of Task, it may take some time until it's available on Scoop.
AUR
If you're on Arch Linux you can install Task from
AUR using your favorite
package manager such as yay
, pacaur
or yaourt
:
yay -S taskfile-git
This installation method is community owned, but since it's -git
version of
the package, it's always latest available version based on the Git repository.
Nix
If you're on NixOS or have Nix installed you can install Task from nixpkgs:
nix-env -iA nixpkgs.go-task
This installation method is community owned. After a new release of Task, it may take some time until it's available in nixpkgs.
Get The Binary
Binary
You can download the binary from the releases page on GitHub and
add to your $PATH
.
DEB and RPM packages are also available.
The task_checksums.txt
file contains the SHA-256 checksum for each file.
Install Script
We also have an install script which is very useful in scenarios like CI. Many thanks to GoDownloader for enabling the easy generation of this script.
# For Default Installation to ./bin with debug logging
sh -c "$(curl --location https://taskfile.dev/install.sh)" -- -d
# For Installation To /usr/local/bin for userwide access with debug logging
# May require sudo sh
sh -c "$(curl --location https://taskfile.dev/install.sh)" -- -d -b /usr/local/bin
This method will download the binary on the local
./bin
directory by default.
GitHub Actions
If you want to install Task in GitHub Actions you can try using this action by the Arduino team:
- name: Install Task
uses: arduino/setup-task@v1
This installation method is community owned.
Build From Source
Go Modules
First, make sure you have Go properly installed and setup.
You can easily install the latest release globally by running:
go install github.com/go-task/task/v3/cmd/task@latest
Or you can install into another directory:
env GOBIN=/bin go install github.com/go-task/task/v3/cmd/task@latest
If using Go 1.15 or earlier, instead use:
env GO111MODULE=on go get -u github.com/go-task/task/v3/cmd/task@latest
For CI environments we recommend using the Install Script instead, which is faster and more stable, since it'll just download the latest released binary.