Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/covenant-gov/pacto-app/llms.txt

Use this file to discover all available pages before exploring further.

This guide walks you through running Pacto on your local machine. By the end you will have the full Tauri v2 desktop app — SvelteKit frontend and Rust backend — running in development mode, connected to live Nostr relays and ready for local experimentation. The entire process takes under 15 minutes on a modern machine (excluding the one-time Cargo compilation step on first run).
1

Install prerequisites

Pacto requires Rust (via rustup), Node.js 20+, and pnpm, plus a set of native system libraries consumed by Tauri and its Rust dependencies. Follow the guide for your operating system:At minimum you need:
ToolMinimum versionInstall
Rust / Cargostable (latest)curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
Node.js20 LTSNodeSource or nvm install 20
pnpmlatestcorepack enable && corepack prepare pnpm@latest --activate
After installing Rust, source the cargo environment so the toolchain is on your PATH:
source "$HOME/.cargo/env"
Verify everything is available:
rustc --version
cargo --version
node --version
pnpm --version
2

Clone and install

Clone the repository and install Node dependencies with pnpm:
git clone https://github.com/covenant-gov/pacto-app.git
cd pacto-app
pnpm install
pnpm reads package.json and installs the SvelteKit frontend dependencies and the Tauri CLI into node_modules. The Rust crate (src-tauri/) is compiled separately in the next steps — pnpm install does not trigger Cargo yet.
3

Configure environment

Copy the example environment file to create your local .env:
cp .env.example .env
The .env.example ships with all keys commented out:
# ALCHEMY_RPC_KEY=
# POCKET_RPC_KEY=
# VITE_WALLET_RPC_DOCS_URL=
Setting ALCHEMY_RPC_KEY to your Alchemy API key gives you reliable, rate-limit-free RPC access to Ethereum, Arbitrum, Optimism, and other supported networks. Without it, Pacto falls back to public RPC endpoints which are sufficient for development but less reliable under load.
Public RPC fallbacks are built in — ALCHEMY_RPC_KEY is optional for local development. You do not need an API key to run the app or explore the UI.
4

Run the desktop app

Launch Pacto in Tauri development mode:
pnpm tauri:dev
Tauri compiles the Rust backend, bundles the SvelteKit frontend, and opens a native desktop window with hot-reload enabled. The Svelte UI reloads instantly on file changes; Rust changes trigger a Cargo recompile.
The first run downloads and compiles all Rust dependencies from crates.io — this is normal and can take several minutes depending on your machine and network connection. Subsequent runs are much faster because Cargo caches compiled artifacts in src-tauri/target/.

Frontend-only mode

If you are working on UI components or Svelte stores and do not need the Rust backend, you can run the SvelteKit dev server directly in a browser:
pnpm dev
This starts Vite’s hot-module-replacement server (typically at http://localhost:5173) without invoking Cargo. Tauri invoke calls and backend events will not be available — commands that cross the Tauri bridge will no-op or throw — but all pure frontend work, layout, and store logic can be developed and previewed instantly.

Troubleshooting

Error:
error: could not find system library 'webkit2gtk-4.1'
Cause: Tauri’s Linux build requires the WebKit rendering engine development package, which is not installed by default on many distributions.Fix:
sudo apt install libwebkit2gtk-4.1-dev
Error:
error: failed to run custom build command for `openssl-sys`
Cause: Several Rust crates link against OpenSSL at compile time and need the development headers (libssl-dev) and pkg-config to locate them.Fix:
sudo apt install libssl-dev pkg-config
Error:
error: failed to run custom build command for `...`
thread 'main' panicked at 'Unable to find libclang'
Cause: Some Rust crates (including those generating FFI bindings at build time) depend on cmake, clang, and libclang-dev being available on the system.Fix:
sudo apt install cmake clang libclang-dev
Error:
command not found: cargo
command not found: rustc
Cause: rustup installs Rust into ~/.cargo/bin, which is not automatically on PATH in the current shell session.Fix (current session):
source "$HOME/.cargo/env"
Fix (permanent — add to shell profile):
echo 'source "$HOME/.cargo/env"' >> ~/.bashrc
source ~/.bashrc
On macOS with zsh, replace ~/.bashrc with ~/.zshrc.

Build docs developers (and LLMs) love