Skip to main content
Geni can be installed using multiple methods depending on your platform and preferences. Choose the installation method that works best for your environment.

Quick Install

macOS

brew install geni

Rust Developers

cargo install geni

Installation Methods

Homebrew (macOS & Linux)

The easiest way to install Geni on macOS or Linux with Homebrew:
brew install geni
Verify the installation:
geni --version
Homebrew automatically adds Geni to your PATH and handles updates via brew upgrade geni.

Verify Installation

After installation, verify that Geni is working correctly:
1

Check Version

Run the version command to ensure Geni is installed:
geni --version
You should see output like:
geni v1.1.9
2

View Help

Display available commands:
geni --help
This will show all available subcommands:
A standalone database CLI migration tool

Usage: geni <COMMAND>

Commands:
  new     Create new migration
  up      Migrate to the latest version
  down    Rollback to last migration
  create  Create database
  drop    Drop database
  status  Show current migrations to apply
  dump    Dump database structure
  help    Print this message or the help of the given subcommand(s)
3

Test with SQLite

Create a test migration with SQLite (no database setup required):
mkdir test-geni && cd test-geni
DATABASE_URL="sqlite://./test.db" geni new test_migration
You should see:
Created migration: migrations/20240302120000_test_migration.up.sql
Created migration: migrations/20240302120000_test_migration.down.sql

Next Steps

Now that you have Geni installed:

Quickstart Tutorial

Follow a hands-on tutorial to create and run your first migration

Configuration

Learn about environment variables and configuration options

Commands Reference

Explore all available Geni commands and their options

Database Setup

Configure Geni for your specific database system

Troubleshooting

If you installed via Cargo, ensure ~/.cargo/bin is in your PATH:
export PATH="$HOME/.cargo/bin:$PATH"
Add this to your ~/.bashrc or ~/.zshrc to make it permanent.
If you downloaded from GitHub releases and get permission errors:
sudo chmod +x /usr/local/bin/geni
Ensure you have write permissions to /usr/local/bin/ or install to a user directory.
When running in Docker, use --network=host to access host databases:
docker run --rm -it --network=host \
  -e DATABASE_URL="postgres://localhost/db" \
  ghcr.io/emilpriver/geni:latest up
Or use the container’s gateway IP to reach the host.

Build docs developers (and LLMs) love