MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / Change

Class Change

atomic-core/src/change/change.rs:125–147  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

123/// per-section zstd compression, and incremental blake3 hashing.
124#[derive(Clone, Debug)]
125pub struct Change {
126 /// The hashed portion (contributes to change hash)
127 pub hashed: HashedChange,
128
129 /// Optional unhashed metadata (JSON)
130 ///
131 /// This can contain arbitrary data that doesn't affect the change hash.
132 /// Useful for storing editor metadata, review comments, AI transcripts, etc.
133 pub unhashed: Option<serde_json::Value>,
134
135 /// Optional Ed25519 signature over the change's content hash.
136 ///
137 /// Excluded from the change hash (the SIGNATURE section is unhashed), so
138 /// re-signing with a different key never changes the change's identity.
139 /// `None` for unsigned (legacy) changes.
140 pub signature: Option<format_v3::ChangeSignature>,
141
142 /// Binary content blob
143 ///
144 /// This contains the actual file content referenced by hunks.
145 /// Hunks reference byte ranges within this blob.
146 pub contents: Vec<u8>,
147}
148
149impl Change {
150 /// Create a new change.

Callers 1

Calls

no outgoing calls

Tested by 1