Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Project Structure

The project uses Cargo workspaces.

Project structure

Cargo Workspace

The workspace defined in Cargo.toml contains three members:

[workspace]
members = [
    "common",
    "program",
    "client",
]

Crates

CratePathPurpose
programprogram/The on-chain Solana counter program (BPF)
clientclient/Rust CLI client that invokes the on-chain program
commoncommon/Shared types (structs, enums) used by both program and client

For experimentation, tweak files under program/, then rebuild and redeploy the on-chain program before re-running the client.