Installation¶
Installers¶
- In your browser, download the
.pkgfile: hatch-1.9.7.pkg - Run your downloaded file and follow the on-screen instructions.
- Restart your terminal.
-
To verify that the shell can find and run the
hatchcommand in yourPATH, use the following command.$ hatch --version 1.9.7
-
Download the file using the
curlcommand. The-ooption specifies the file name that the downloaded package is written to. In this example, the file is written tohatch-1.9.7.pkgin the current directory.curl -o hatch-1.9.7.pkg https://github.com/pypa/hatch/releases/download/hatch-v1.9.7/hatch-1.9.7.pkg -
Run the standard macOS
installerprogram, specifying the downloaded.pkgfile as the source. Use the-pkgparameter 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/hatchthat instructs shells to add the/usr/local/hatchdirectory to. You must include sudo on the command to grant write permissions to those folders.sudo installer -pkg ./hatch-1.9.7.pkg -target / -
Restart your terminal.
-
To verify that the shell can find and run the
hatchcommand in yourPATH, use the following command.$ hatch --version 1.9.7
- In your browser, download one the
.msifiles: - Run your downloaded file and follow the on-screen instructions.
- Restart your terminal.
-
To verify that the shell can find and run the
hatchcommand in yourPATH, use the following command.$ hatch --version 1.9.7
-
Download and run the installer using the standard Windows
msiexecprogram, specifying one of the.msifiles as the source. Use the/passiveand/iparameters to request an unattended, normal installation.msiexec /passive /i https://github.com/pypa/hatch/releases/download/hatch-v1.9.7/hatch-1.9.7-x64.msi -
Restart your terminal.
-
To verify that the shell can find and run the
hatchcommand in yourPATH, use the following command.$ hatch --version 1.9.7
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.
pip install hatch
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.
pipx install hatch
Homebrew¶
See the formula for more details.
brew install hatch
Conda¶
See the feedstock for more details.
conda install -c conda-forge hatch
or with mamba:
mamba install hatch
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.
sudo port install hatch
Fedora¶
The minimum supported version is 37, currently in development as Rawhide.
sudo dnf install hatch
Void Linux¶
xbps-install hatch
Build system availability¶
Hatchling is Hatch's build backend which you will never need to install manually. See its changelog for version information.