Docs exports: JSON llms.txt llms-full.txt Agent Files

module Shards::Checksum

Defined in:

checksum.cr

Constant Summary

ALGORITHM_PREFIX = "sha256"
EXCLUDED_DIRS = {".git", ".hg", ".fossil", ".fslckout", "_FOSSIL_"}

Class Method Summary

Class Method Detail

def self.compute(path : String) : String #

Compute a deterministic SHA-256 checksum for a directory of source files. Returns a string like "sha256:abcdef1234..."


[View source]
def self.verify(path : String, expected : String) : Bool #

Verify a checksum against a directory. Returns true if match, false if mismatch.


[View source]