module
Shards::Checksum
Defined in:
checksum.crConstant Summary
-
ALGORITHM_PREFIX =
"sha256" -
EXCLUDED_DIRS =
{".git", ".hg", ".fossil", ".fslckout", "_FOSSIL_"}
Class Method Summary
-
.compute(path : String) : String
Compute a deterministic SHA-256 checksum for a directory of source files.
-
.verify(path : String, expected : String) : Bool
Verify a checksum against a directory.
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..."
def self.verify(path : String, expected : String) : Bool
#
Verify a checksum against a directory. Returns true if match, false if mismatch.