# Packages and installers

> Install Elide with Homebrew, apt, RPM, or the macOS and Windows installers, upgrade through the package manager, and verify checksums and signatures.

Upgrade these installs through their package manager, not `elide upgrade`. Only Homebrew includes Python; see
[Installation](https://elide.help/docs/installation#python).

## Homebrew

```bash
brew install elide-dev/elide/elide
brew upgrade elide
```

The [`elide-dev/homebrew-elide`](https://github.com/elide-dev/homebrew-elide) tap tracks `nightly` on macOS (Apple
Silicon) and Linux (`amd64`, `arm64`).

## Debian and Ubuntu (apt)

```bash
curl -fsSL https://keys.elide.dev/gpg.key | sudo gpg --dearmor -o /usr/share/keyrings/elide.gpg
echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/elide.gpg]" \
  "https://dl.elide.dev release main" | sudo tee /etc/apt/sources.list.d/elide.list
sudo apt update && sudo apt install elide
```

Replace `release` with `nightly` for daily builds. Upgrade with `sudo apt update && sudo apt upgrade elide`. The
package installs into `/opt/elide/<version>`, with `/opt/elide/current` and `/usr/bin/elide` pointing at it.

## Fedora and RHEL (RPM)

```bash
sudo dnf install ./elide_<version>_<arch>.rpm
```

Download the RPM for `amd64` or `arm64` from [GitHub Releases](https://github.com/elide-dev/elide/releases); there
is no yum repository. Upgrade by installing a newer RPM.

## Native installers

These links point at the latest `release`; replace `release` with `nightly` in a URL for the latest nightly.

| Platform | Format | Download | Checksum |
| --- | --- | --- | --- |
| macOS `arm64` | PKG | [elide-installer.macos-arm64.pkg](https://elide.zip/artifacts/release/latest/elide-installer.macos-arm64.pkg) | [sha256](https://elide.zip/artifacts/release/latest/elide-installer.macos-arm64.pkg.sha256) |
| macOS `arm64` | DMG | [elide-installer.macos-arm64.dmg](https://elide.zip/artifacts/release/latest/elide-installer.macos-arm64.dmg) | [sha256](https://elide.zip/artifacts/release/latest/elide-installer.macos-arm64.dmg.sha256) |
| Windows `amd64` | MSI | [elide-installer.windows-amd64.msi](https://elide.zip/artifacts/release/latest/elide-installer.windows-amd64.msi) | [sha256](https://elide.zip/artifacts/release/latest/elide-installer.windows-amd64.msi.sha256) |

## Verify a download

Each installer has a SHA-256 checksum (`<file>.sha256`) and a GPG signature (`<file>.asc`). GitHub Releases also
carries a Sigstore bundle (`<file>.bundle`).

With the download and its `.sha256` file in one directory:

```bash
sha256sum -c <file>.sha256        # Linux
shasum -a 256 -c <file>.sha256    # macOS
```

PowerShell:

```powershell
$file = "elide-installer.windows-amd64.msi"
Invoke-WebRequest -Uri "https://elide.zip/artifacts/release/latest/$file" -OutFile $file
Invoke-WebRequest -Uri "https://elide.zip/artifacts/release/latest/$file.sha256" -OutFile "$file.sha256"
$expected = (Get-Content "$file.sha256").Split(" ")[0]
$actual = (Get-FileHash $file -Algorithm SHA256).Hash.ToLower()
if ($expected -eq $actual) { Write-Host "OK" } else { Write-Host "MISMATCH" }
```

Signature:

```bash
curl -fsSL https://keys.elide.dev/gpg.key | gpg --import
curl -LO https://elide.zip/artifacts/release/latest/elide-installer.windows-amd64.msi.asc
gpg --verify elide-installer.windows-amd64.msi.asc elide-installer.windows-amd64.msi
```

A valid signature reports `Good signature from "Elide Releases (Release key, Elide 1.0 and up)
<engineering@elide.dev>"`. GPG warns that the key is not certified until you sign it yourself.
