Files
herolib/lib/core/pathlib/path_crypto.v
2024-12-25 09:23:31 +01:00

10 lines
159 B
V

module pathlib
import crypto.sha256
// return sha256 hash of a file
pub fn (mut path Path) sha256() !string {
c := path.read()!
return sha256.hexhash(c)
}