Installation

Prerequisites, .env, CLI commands, quick start.

● ● ●
[workspace]
members = ["myapp"]
resolver = "3"

[workspace.package]
version = "0.1.0"
edition = "2024"
rust-version = "1.94"

[workspace.dependencies]
# pick exactly one engine: sqlite, postgres, mysql or mariadb
runique = { version = "4.0.0", features = ["postgres"] }
tokio   = { version = "1", features = ["full"] }
serde   = { version = "1", features = ["derive"] }
SECRET_KEY=a_long_random_secret_key
DATABASE_URL=postgres://user:password@localhost:5432/my_database
DEBUG=true
# Install the CLI — with your database engine
cargo install runique --features postgres --locked

# Generate the project
runique new my-project
cd my-project
cargo run            # normal Rust binary — no runique start

# Superuser / tests
runique create-superuser
runique test

# Migrations
runique makemigrations --entities src/entities --migrations migration/src
runique migration up --migrations migration/src

# Roll back the last one / list them
runique migration down -n 1
runique migration status