Skip to main content

mcp_repl/
lifecycle.rs

1//! Project lifecycle and release contract.
2//!
3//! `mcp-repl` began as an example in the
4//! [tower-mcp](https://github.com/joshrotenberg/tower-mcp) workspace and moved
5//! to this standalone repository at version 0.2.0 (2026-08-04). The move used
6//! `git filter-repo`, so `git log --follow` traces every source file back to
7//! its original tower-mcp commits. Versions before 0.2.0 were released from
8//! the tower-mcp repository; their tags and release notes remain there.
9//!
10//! # Supported boundaries
11//!
12//! The application lives in the `mcp_repl` library and the binary is only a
13//! thin call to [`crate::run_cli`]. The deliberately reusable seams are:
14//!
15//! - [`crate::config`] for native server and alias profiles;
16//! - [`crate::import_config`] for explicit imports from standard MCP JSON
17//!   configuration files; and
18//! - [`crate::oauth_profile`] for non-secret OAuth profile metadata and secure
19//!   credential-store access.
20//!
21//! Terminal editing, rendering, and command dispatch remain private. A related
22//! tool such as `mcp2md` should not depend on all of `mcp-repl` merely to reuse
23//! configuration: that would also couple it to the interactive terminal stack.
24//! Keep such a tool independent unless real duplication justifies extracting a
25//! narrow configuration or connection crate used by both projects.
26//!
27//! # Compatibility and release lanes
28//!
29//! The default CI lane builds against the released `tower-mcp` declared in the
30//! manifest, which is what users install:
31//!
32//! ```text
33//! cargo fmt --all -- --check
34//! cargo clippy --all-targets --all-features -- -D warnings
35//! cargo test --all-targets --all-features
36//! RUSTDOCFLAGS=-Dwarnings cargo doc --no-deps --all-features
37//! cargo package
38//! ```
39//!
40//! A scheduled job additionally patches `tower-mcp` to git main and reruns the
41//! test suite. That lane preserves the early-warning role this project played
42//! inside the workspace: an upstream client-surface break shows up here within
43//! a day instead of at the next framework release. A failure that reproduces
44//! only in that job indicates tower-mcp main moved, not an mcp-repl
45//! regression.
46//!
47//! This repository's release-plz workflow owns crates.io publication, tags,
48//! GitHub releases, and changelog updates. Do not publish a version manually
49//! in parallel with it.
50//!
51//! # Test fixture
52//!
53//! The black-box tests spawn `examples/mcp_repl_fixture.rs`, a deterministic
54//! MCP server built from this repository's dev-dependencies. It is excluded
55//! from the published package; the `examples/` directory here exists for the
56//! test suite, not for documentation.