tools tier

tools-merge-resolve

Classify and resolve the merge-conflict classes this workspace produces repeatedly

Classify and resolve the merge-conflict classes this workspace produces repeatedly

Tiertools
Roleunclassified (baselined)
Pathcrates/tools/merge-resolve
Edition2021
Targetstools-merge-resolve, tools_merge_resolve, cli_test
Public items6 across 0 modules
Tests16

What it is for

Classify and resolve the merge conflicts this workspace produces repeatedly.

Three conflict classes account for nearly every merge collision here, and each has one correct resolution that is a property of the file, not a judgment about the change:

hand". Both sides are machine output from different commits, so picking a side is always wrong: the answer is to regenerate after the merge. Taking either side silently produces an index that describes neither parent.

adding entries is not a disagreement; both sets are true and the resolution is the union, ours first. Choosing one side deletes shipped history.

regenerating, never by merging text.

Anything else is a real disagreement about content and this tool refuses it. Refusing loudly is the point: a resolver that guesses at genuine conflicts is worse than no resolver, because its output looks reviewed.

Capabilities

crate root

Classify and resolve the merge conflicts this workspace produces repeatedly.

Item
fn resolve_ledger(content : & str) -> Result <String, String>
fn regeneration_command(path : & str) -> Option <& 'static str>

Class

Classify and resolve the merge conflicts this workspace produces repeatedly.

Item
pub enum Class
fn classify(path : & str, content : & str) -> Class

Hunk

Classify and resolve the merge conflicts this workspace produces repeatedly.

Item
pub struct Hunk
fn parse_hunks(content : & str) -> Result <Vec <Hunk>, String>

How to use it

No examples/ target and no doctest in this crate's rustdoc. The tests listed under Verification are the closest executable usage.

Module structure

No public modules: the crate root is its whole surface.

Public surface

`crate root`

ItemWhat it is
pub enum ClassWhat kind of conflict a path holds, which determines the only correct resolution.
fn classify(path : & str, content : & str) -> ClassClassify by path and content together
pub struct HunkOne parsed conflict hunk.
fn parse_hunks(content : & str) -> Result <Vec <Hunk>, String>Parse every conflict hunk
fn resolve_ledger(content : & str) -> Result <String, String>Resolve a ledger conflict by keeping both sides, ours first
fn regeneration_command(path : & str) -> Option <& 'static str>The command that rebuilds a generated file, if this tool knows one.

No pub use re-exports: every item above is declared in this crate.

Boundary

Depends on no other workspace tier.

Shares tier tools with 84 other crates: tools-advisory-reach, tools-archive-guard, tools-artifact-scaffold, tools-ask-ai-core, tools-ask-ais, tools-ask-gemini, tools-book, tools-book-report, … (84 total).

_What this crate deliberately does NOT own is a judgment. No committed registry records one for it, so none is stated here._

Where it sits

Tier (ontology)tools
Architectural role (taxonomy)unclassified (baselined)
Locationcrates/tools/merge-resolve
Vocabulary in force (lexicon)current

Dependencies

Runtime. None.

Development, from outside the workspace.

CrateRequirementFeaturesOptionalOnly on
tempfile^3noalways

Build. None.

Depended on by. Nothing in this workspace.

Feature flags

No Cargo features are defined: every capability is unconditional, so no consumer can receive a half-wired crate.

Targets

KindNameSource
bintools-merge-resolve`src/main.rs`
libtools_merge_resolve`src/lib.rs`
testcli_test`tests/cli_test.rs`

Error model

No public error type was detected: no public item declares a type named *Error, and no public signature returns one.

Operational characteristics

PropertyEvidence
async public surfacenone detected
async runtimenone detected
database accessnone detected
network I/Onone detected
unsafe codenone detected
environment variablesnone detected

No unsafe block, unsafe fn, unsafe impl or unsafe trait was found by the parser anywhere in this crate's source.

Configuration

No environment variable is read with a literal name anywhere in this crate. A variable whose key is computed at run time cannot be listed here, and is not claimed to be absent.

No workspace crate depends on this one.

Verification

KindCount
Unit tests13
Integration tests3
Examples0
Doctests0

Evidence by module. How often each public module is named by something executable.

ModuleTestsExamplesConsumers
crate root600

What the tests establish, by name:

Documentation coverage

MeasureDocumentedTotal
Public items with rustdoc66
Public modules with a //! block00
pie showData
    title Public items with rustdoc
    "Documented" : 6
    "No rustdoc detected" : 0

Metrics

MetricValue
Rust source files2
Source lines399
Code lines287
Public API items6
Public modules0
Tests16
Examples0
Cargo features0
Direct runtime dependencies0
Workspace reverse dependencies0
pie showData
    title Public API by kind
    "enum" : 1
    "function" : 4
    "struct" : 1
pie showData
    title Rust source composition
    "Code" : 287
    "Blank or comment" : 112

Generation

Rendered by tools-corpus corpus readme from repository evidence alone, renderer schema 2, lexicon current. No model, network service or database was consulted. Regenerate with tools-corpus corpus readme --write; verify with --check.

All tools · Manual