Skip to main content

CLI Installation


title: CLI Installation audience: Developer difficulty: Beginner estimated_read_time: 3 min prerequisites:

  • Terminal access
  • curl or wget available related_pages:
  • ../getting-started/installation.md
  • ./index.md

Complete guide to installing the envcat CLI on your machine.

Quick Install

One-line installer (recommended):

curl -fsSL https://env.cat/cli/install.sh | bash

This installer:

  • Auto-detects your platform (macOS/Linux, Intel/ARM)
  • Downloads the correct binary
  • Installs to /usr/local/bin/envcat
  • Verifies the installation

Platform-Specific Installation

macOS

Apple Silicon (M1/M2/M3):

curl -fsSL https://env.cat/cli/darwin-arm64/envcat -o envcat
chmod +x envcat
sudo mv envcat /usr/local/bin/

Intel (x86_64):

curl -fsSL https://env.cat/cli/darwin-amd64/envcat -o envcat
chmod +x envcat
sudo mv envcat /usr/local/bin/

Linux

x86_64 (most common):

curl -fsSL https://env.cat/cli/linux-amd64/envcat -o envcat
chmod +x envcat
sudo mv envcat /usr/local/bin/

ARM64 (Raspberry Pi, ARM servers):

curl -fsSL https://env.cat/cli/linux-arm64/envcat -o envcat
chmod +x envcat
sudo mv envcat /usr/local/bin/

Windows

Windows Subsystem for Linux (WSL):

  1. Install WSL if you haven't already:

    wsl --install
  2. Inside WSL, follow Linux installation steps:

    curl -fsSL https://env.cat/cli/linux-amd64/envcat -o envcat
    chmod +x envcat
    sudo mv envcat /usr/local/bin/

Native Windows support is planned for a future release.

Alternative Installation Methods

Install to Custom Directory

If you don't have sudo access or prefer a different location:

# Install to ~/.local/bin
mkdir -p ~/.local/bin
curl -fsSL https://env.cat/cli/darwin-arm64/envcat -o ~/.local/bin/envcat
chmod +x ~/.local/bin/envcat

# Add to PATH (if not already)
echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.bashrc
source ~/.bashrc

Build from Source

Prerequisites:

  • Go 1.21 or later
  • Git

Steps:

# Clone repository
git clone https://github.com/check-the-vibe/envcat.git
cd envcat/cli

# Build
go build -o envcat ./cmd/envcat

# Install
sudo mv envcat /usr/local/bin/

# Verify
envcat --version

Verify Installation

After installation, verify the CLI works:

# Check version
envcat --version
# envcat version v0.1.0

# Check help
envcat --help
# Shows usage and available commands

# Test connectivity (production)
envcat get --api-base https://env.cat --bundle dev/example
# Should display approval URL

Updating the CLI

To update to the latest version:

# Re-run the installer
curl -fsSL https://env.cat/cli/install.sh | bash

# Or download manually
curl -fsSL https://env.cat/cli/darwin-arm64/envcat -o envcat
chmod +x envcat
sudo mv envcat /usr/local/bin/

Check for updates:

# Current version
envcat --version

# Latest version
curl -fsSL https://env.cat/cli/VERSION

Configuration

Default API Endpoint

The CLI defaults to the production API:

  • Production: https://env.cat

Override with --api-base flag:

# Use local development instance
envcat get --api-base http://localhost:8888 --bundle dev/example

Environment Variables

Set default configuration via environment variables:

# Set default API base
export ENVCAT_API_BASE=https://env.cat

# Now you can omit --api-base flag
envcat get --bundle dev/example

Add to shell profile for persistence:

# For bash
echo 'export ENVCAT_API_BASE=https://env.cat' >> ~/.bashrc

# For zsh
echo 'export ENVCAT_API_BASE=https://env.cat' >> ~/.zshrc

Troubleshooting

"envcat: command not found"

Cause: Binary not in PATH.

Solution 1 - Check installation location:

ls -l /usr/local/bin/envcat

Solution 2 - Add to PATH:

export PATH="/usr/local/bin:$PATH"

Solution 3 - Use full path:

/usr/local/bin/envcat --version

"Permission denied"

Cause: Binary not executable.

Solution:

chmod +x /usr/local/bin/envcat

"curl: (60) SSL certificate problem"

Cause: SSL certificate verification failed.

Solution (not recommended for production):

curl -k -fsSL https://env.cat/cli/install.sh | bash

Better solution: Update CA certificates:

# macOS
brew update && brew upgrade

# Linux (Ubuntu/Debian)
sudo apt update && sudo apt upgrade ca-certificates

Installation hangs or times out

Cause: Network issues or slow connection.

Solution: Download directly and install manually:

# Download binary
curl -L https://env.cat/cli/darwin-arm64/envcat -o envcat

# Verify download succeeded
ls -lh envcat

# Install
chmod +x envcat
sudo mv envcat /usr/local/bin/

Uninstall

To remove the CLI:

# Remove binary
sudo rm /usr/local/bin/envcat

# Verify removal
envcat --version
# Should show: command not found

Next Steps

Now that the CLI is installed:

Getting Started - First run guide
CLI Commands - Command reference
Examples - Usage examples

Support

Having trouble with installation?