Installation - Hatch (original) (raw)
GitHub Actions¶
- name: Install Hatch uses: pypa/hatch@install
Refer to the official action for more information.
Installers¶
macOSWindows
GUI installerCommand line installer
In your browser, download the
.pkg
file: hatch-universal.pkgRun your downloaded file and follow the on-screen instructions.
Restart your terminal.
To verify that the shell can find and run the
hatch
command in yourPATH
, use the following command.Download the file using the
curl
command. The-o
option specifies the file name that the downloaded package is written to. In this example, the file is written tohatch-universal.pkg
in the current directory.curl -Lo hatch-universal.pkg https://github.com/pypa/hatch/releases/latest/download/hatch-universal.pkg
Run the standard macOS installer program, specifying the downloaded
.pkg
file as the source. Use the-pkg
parameter to specify the name of the package to install, and the-target /
parameter for the drive in which to install the package. The files are installed to/usr/local/hatch
, and an entry is created at/etc/paths.d/hatch
that instructs shells to add the/usr/local/hatch
directory to. You must include sudo on the command to grant write permissions to those folders.sudo installer -pkg ./hatch-universal.pkg -target /
Restart your terminal.
To verify that the shell can find and run the
hatch
command in yourPATH
, use the following command.
GUI installerCommand line installer
In your browser, download one the
.msi
files:Run your downloaded file and follow the on-screen instructions.
Restart your terminal.
To verify that the shell can find and run the
hatch
command in yourPATH
, use the following command.Download and run the installer using the standard Windows msiexec program, specifying one of the
.msi
files as the source. Use the/passive
and/i
parameters to request an unattended, normal installation.
x64x86msiexec /passive /i https://github.com/pypa/hatch/releases/latest/download/hatch-x64.msi
msiexec /passive /i https://github.com/pypa/hatch/releases/latest/download/hatch-x86.msi
Restart your terminal.
To verify that the shell can find and run the
hatch
command in yourPATH
, use the following command.
Standalone binaries¶
After downloading the archive corresponding to your platform and architecture, extract the binary to a directory that is on your PATH and rename to hatch
.
pip¶
Hatch is available on PyPI and can be installed with pip.
Warning
This method modifies the Python environment in which you choose to install. Consider instead using pipx to avoid dependency conflicts.
pipx¶
pipx allows for the global installation of Python applications in isolated environments.
Homebrew¶
See the formula for more details.
Conda¶
See the feedstock for more details.
conda install -c conda-forge hatch
or with mamba:
Warning
This method modifies the Conda environment in which you choose to install. Consider instead using pipx or condax to avoid dependency conflicts.
MacPorts¶
See the port for more details.
Fedora¶
The minimum supported version is 37, currently in development as Rawhide.
Void Linux¶
Build system availability¶
Hatchling is Hatch's build backend which you will never need to install manually. See its changelog for version information.