gitattributes

This commit is contained in:
Worph
2026-07-14 16:09:01 +02:00
parent fec2eb105d
commit 7f4beb6c06
2 changed files with 14 additions and 5 deletions
+6
View File
@@ -0,0 +1,6 @@
# FIX CRLF always when developer has not set
# Linux/Mac: git config --global core.autocrlf input
# Windows: git config --global core.autocrlf true
# Auto detect text files and perform LF normalization
* text=auto
* eol=lf
+8 -5
View File
@@ -461,11 +461,14 @@ export class RedisClient implements Partial<IKVClient> {
ctime: data.ctime ? parseFloat(data.ctime) : mtime, ctime: data.ctime ? parseFloat(data.ctime) : mtime,
// Identification. The midhash (record address) and the full-file // Identification. The midhash (record address) and the full-file
// sha2-256 (exact-dup key) are recovered from the bare-CID // sha2-256 (exact-dup key) are recovered from the bare-CID key-set by
// key-set by multicodec; legacy named fields kept as a // multicodec. The legacy `cid_midhash256` / `cid_sha2-256` fallbacks
// transition fallback. See METADATA_KEYS.md §2/§14.13. // are gone: meta-core rejects those fields at the write boundary now
hashId: hashId ?? pickCidByMulticodec(data, MH_MIDHASH256) ?? data.cid_midhash256 ?? data.hashId, // (400), because a `cid_*` field is stored but never reverse-indexed —
sha256: pickCidByMulticodec(data, MH_SHA256) ?? data['cid_sha2-256'] ?? data.sha256, // a record carrying one is unresolvable by that CID. There is nothing
// left to fall back to. See METADATA_KEYS.md §2/§14.13.
hashId: hashId ?? pickCidByMulticodec(data, MH_MIDHASH256) ?? data.hashId,
sha256: pickCidByMulticodec(data, MH_SHA256) ?? data.sha256,
// Title information // Title information
title: data.title, title: data.title,