Skip to content
Edit this page View source of this page

Pegg Installation

Pegg ships as a single static binary with no runtime dependencies. Release builds are produced for Linux, macOS, and Windows on both amd64 and arm64.

Requirements

Runtime None — the binary is self-contained (CGO_ENABLED=0)
Build from source Go 1.26.5 or newer
Windows installer Windows PowerShell 5.1+ or PowerShell 7+
Terminal Any modern terminal. The TUI uses 24-bit color and mouse/paste support when available
VS Code extension VS Code 1.90+ with a trusted workspace

Install

curl -fsSL https://pegg.dev/install | bash

Downloads the latest release binary for your platform and installs it to /usr/local/bin when that directory is writable, and to ~/.local/bin otherwise. When the install directory is not already on your PATH, the installer appends an export to your login shell's profile (~/.zshrc, ~/.bash_profile on macOS, ~/.bashrc on Linux, or a fish/conf.d/pegg.fish snippet), so pegg resolves in new shells.

Pick the directory with PREFIX, pin a release with VERSION, or skip the PATH update with PEGG_NO_PATH:

curl -fsSL https://pegg.dev/install | PREFIX=$HOME/bin VERSION=v0.1.8 bash
irm https://pegg.dev/install.ps1 | iex

From cmd.exe:

powershell -NoProfile -ExecutionPolicy Bypass -Command "irm https://pegg.dev/install.ps1 | iex"

Installs pegg.exe to %LOCALAPPDATA%\Programs\pegg and adds that directory to your user PATH. Override the location with PREFIX:

$env:PREFIX = "$env:USERPROFILE\bin"
irm https://pegg.dev/install.ps1 | iex

Pin a release with VERSION, or skip the PATH update with PEGG_NO_PATH:

$env:VERSION = 'v0.1.8'
irm https://pegg.dev/install.ps1 | iex
code --install-extension peggco.pegg-vscode

Or install Pegg from the Extensions view. The extension can download and verify the matching pegg binary automatically, so a separate CLI install is optional. See the VS Code guide.

npm i -g @peggco/pegg

Installs the pegg binary globally via npm.

  • Pin a version: PEGG_VERSION=v0.1.5 npm i -g @peggco/pegg
  • Skipped install scripts (--ignore-scripts, or pnpm blocking build scripts) leave no binary; reinstall without them, or for pnpm run pnpm approve-builds.
  • npm 11+ may block scripts until approved: npm i -g --allow-scripts=@peggco/pegg.

Download the archive for your platform from the GitHub releases page:

Platform Archive
Linux pegg_linux_amd64.tar.gz, pegg_linux_arm64.tar.gz
macOS pegg_darwin_amd64.tar.gz, pegg_darwin_arm64.tar.gz
Windows pegg_windows_amd64.zip, pegg_windows_arm64.zip
# Example: Linux amd64
tar -xzf pegg_linux_amd64.tar.gz
sudo mv pegg /usr/local/bin/

Each release also publishes checksums.txt so you can verify your download:

sha256sum -c checksums.txt --ignore-missing

Desktop releases publish a separate pegg-desktop_checksums.txt covering the pegg-desktop_* archives, installers, and packages:

sha256sum -c pegg-desktop_checksums.txt --ignore-missing
go install github.com/peggco/pegg/cmd/pegg@latest

The binary is placed in $(go env GOPATH)/bin. Make sure that directory is on your PATH.

git clone https://github.com/peggco/pegg.git
cd pegg
make build        # produces ./bin/pegg
make run          # or run it immediately

Other useful targets: make test, make lint, make fmt, make vet, make clean.

Verify

pegg version
# pegg version 0.1.0

First run

The first launch creates the global config directory and a default config file, and creates a project-local .pegg/ directory in the current working directory.

pegg login

The login command opens an interactive provider picker, then asks for an API key (masked). Keys are stored in ~/.peggco/pegg.json. You can skip the interactive prompt:

pegg login --provider openai --api-key sk-...

Once at least one provider is configured, start the TUI:

pegg

Or open the Pegg extension in VS Code and run Pegg: Provider Login from the command palette. See the VS Code guide.

Or run a one-shot headless prompt:

pegg run "Summarize this repository"
echo "Fix the failing test" | pegg

See CLI usage for every command.

Update

Pegg can update itself in place from GitHub releases:

pegg update

pegg doctor also checks for updates after testing provider connectivity and offers to install a newer version when one is available.

File locations

Run pegg files to print the resolved paths and whether each exists.

Purpose Path
Global config ~/.peggco/pegg.json
Logs ~/.pegg/logs.db (SQLite driver)
Model cache ~/.pegg/cache.db (SQLite driver)
Sessions ~/.pegg/sessions.db (SQLite driver)
Permission approvals ~/.pegg/permissions.json
Global skills ~/.pegg/skills/
Global rules ~/.pegg/rules/
Downloaded LSP binaries ~/.pegg/lsps/
Read-hash snapshots ~/.pegg/vfs/ (one file per workspace)
Project data <project>/.pegg/
Project MCP config <project>/.mcp.json
Project LSP config <project>/.lsp.json

On Windows, ~ resolves to %USERPROFILE%.

Uninstall

rm "$(command -v pegg)"    # remove the binary
rm -rf ~/.pegg             # remove config, sessions, logs, cache, skills, rules
Remove-Item "$env:LOCALAPPDATA\Programs\pegg" -Recurse -Force
Remove-Item "$env:USERPROFILE\.pegg" -Recurse -Force
Remove-Item "$env:USERPROFILE\.peggco" -Recurse -Force   # provider credentials

If you used a custom PREFIX, remove that directory instead. You can also remove the install directory from your user PATH.

Project-local data lives in each project's .pegg/ directory and can be removed individually.