mirror of
https://github.com/nim-lang/Nim.git
synced 2026-04-27 09:43:58 +00:00
* move sha1, md5 to nimble packages * boot the compiler * fixes tests * build the documentation * fixes docs * lol, I forgot koch.nim * add `nimHasChecksums` define * clone checksums but maybe copying is better * bump nimble hash * use ChecksumsStableCommit * fixes tests * deprecate them * fixes paths * fixes koch
This commit is contained in:
@@ -26,6 +26,9 @@ runnableExamples("-r:off"):
|
||||
b = parseSecureHash("10DFAEBF6BFDBC7939957068E2EFACEC4972933C")
|
||||
assert a == b, "files don't match"
|
||||
|
||||
|
||||
{.deprecated: "use command `nimble install checksums` and import `checksums/sha1` instead".}
|
||||
|
||||
import strutils
|
||||
from endians import bigEndian32, bigEndian64
|
||||
|
||||
@@ -281,4 +284,4 @@ proc `==`*(a, b: SecureHash): bool =
|
||||
|
||||
proc isValidSha1Hash*(s: string): bool =
|
||||
## Checks if a string is a valid sha1 hash sum.
|
||||
s.len == 40 and allCharsInSet(s, HexDigits)
|
||||
s.len == 40 and allCharsInSet(s, HexDigits)
|
||||
Reference in New Issue
Block a user