Skip to main content

clankerdiff_core/
lib.rs

1pub mod anchor;
2pub mod commands;
3pub mod content;
4pub mod error;
5pub mod models;
6pub mod parser;
7pub mod patch;
8pub mod presentation;
9pub mod review;
10pub mod session;
11
12#[cfg(any(test, feature = "test-support"))]
13pub mod testing;
14
15pub use anchor::LineAnchor;
16pub use clankerdiff_fingerprint::{Fingerprint, FingerprintError, SourceSequenceId, join_lines};
17pub use commands::{
18    CommandContext, DiffReviewCommand, FocusPane, InteractionPhase, ReviewCapabilities,
19    ReviewCommand,
20};
21pub use content::{
22    MAX_SOURCE_FILE_BYTES, MAX_SOURCE_FILE_LINES, SourceDocument, SourceLineRef, SourceLocation,
23    SourceResult, SourceUnavailable,
24};
25pub use error::{DiffError, ParseDiffScopeError, RepoPathError};
26pub use models as model;
27pub use models::{
28    DiffDocument, DiffScope, DiffSide, FileDiff, FileStatus, Hunk, ModeChange, PatchLine,
29    PatchLineKind, RepoPath, StageState,
30};
31pub use parser::{
32    GitStatusEntry, UntrackedFile, parse_git_diff, parse_git_diff_with_path_mapper,
33    parse_porcelain_v1_z,
34};
35pub use patch::{PatchError, git_patch_from_texts};
36pub use presentation::{
37    CellContext, ContentProjection, DiffPresentation, DiffTone, GapExpansion, GapId, GapInfo,
38    GapInterval, HunkSequence, Layout, MAX_HUNK_SEQUENCE_LINES, PresentationOptions, PresentedCell,
39    PresentedRow, RowId, RowKind, ViewMode, gaps_for_file,
40};
41pub use review::{
42    AgentFeedbackOptions, CommentContext, DiffReviewEvent, RepositoryAction, Review, ReviewComment,
43    ReviewSubmission, format_review,
44};
45pub use session::{CommentDraft, RevealAmount, ReviewSession, SessionOptions};