Skip to content

chore: scaffold Cargo workspace with three crates#26

Merged
obchain merged 3 commits intomainfrom
feat/01-scaffold-workspace
Apr 24, 2026
Merged

chore: scaffold Cargo workspace with three crates#26
obchain merged 3 commits intomainfrom
feat/01-scaffold-workspace

Conversation

@obchain
Copy link
Copy Markdown
Owner

@obchain obchain commented Apr 21, 2026

Closes #2

Initial Cargo workspace with three member crates:

  • charon-core — shared types, traits, config
  • charon-scanner — chain listener and health-factor scanner
  • charon-cli — command-line entry point (charon binary)

Workspace-level dependency versions pinned centrally in [workspace.dependencies] so member crates reference them with .workspace = true as they begin consuming them.

cargo build --workspace runs clean with no external deps yet compiled (added per-crate in subsequent PRs).

Set up the initial Cargo workspace with resolver=2 and edition=2024.
Three empty member crates scaffolded for future work:

  - charon-core: shared types, traits, and config
  - charon-scanner: chain listener and health-factor scanner
  - charon-cli: command-line entrypoint

Shared dependency versions pinned centrally in [workspace.dependencies]
(tokio, alloy, serde, toml, tracing, anyhow, clap) so each crate can
reference them via `.workspace = true` as they begin consuming them.

.gitignore excludes target/, .env, .DS_Store, and common IDE dirs.
Cargo.lock is committed — standard practice for binary workspaces.
obchain added 2 commits April 22, 2026 20:07
…LI deps

- rust-toolchain.toml pins channel 1.85.0 for reproducible builds
  across dev, CI, and the Docker deploy stack.
- Cargo.toml [workspace] sets resolver = "3" to match the edition
  2024 default (avoids feature-unification drift in alloy/tokio).
- [workspace.lints] forbids unsafe_code and denies the arithmetic /
  cast-truncation / unwrap clippy lints workspace-wide; each crate
  now inherits via [lints] workspace = true.
- crates/charon-cli/Cargo.toml wires the workspace-level tokio, clap,
  anyhow, tracing, tracing-subscriber, and charon-core dependencies
  so the next feature PR is a pure logic addition.

Closes #60 #61 #62 #63
@obchain obchain merged commit b2b3a3b into main Apr 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[chore] Scaffold Cargo workspace with three crates

1 participant