/** * Cross-platform file-mode portability for the `hq-mode` metadata stamp. * * Windows has no POSIX permission bits. Node synthesizes `0o666` for every * writable file and `0o444` for a read-only one, so a Windows uploader that * stamps `lstat.mode & 0o777` ships a mode that says "writable by everyone, * executable by nobody". A POSIX receiver that honours it strips the exec * bit from every hook and script and leaves the file world-writable * (observed 2026-10-01: ~460 `core/` and `.claude/` scripts on a Mac lost * `+x` after a Windows machine pushed its scaffold through the personal * vault). * * Two layers, both small: * 1. Uploader: a win32 source stamps no `hq-mode` at all. The receiver's * existing missing-stamp fallback then keeps the local file's mode. * 2. Receiver: a stamp of exactly `666` or `444` is treated as "no signal" * too. That covers objects already in the vault from older Windows * clients. A genuine POSIX `0o666`/`0o444` file loses nothing the * receiver would not already have from the existing local file, and a * fresh file lands on the umask default as any legacy object does. */ /** * The `hq-mode` value to stamp for a regular file, or `undefined` when the * source platform cannot express a meaningful mode. */ export declare function portableModeStamp(mode: number, platform?: NodeJS.Platform): string | undefined; /** * Whether a parsed `hq-mode` value carries real permission intent. Returns * false for the win32 synthetic modes so the receiver falls back exactly as * it does for a missing stamp. */ export declare function isPortableModeSignal(mode: number): boolean; //# sourceMappingURL=file-mode-portability.d.ts.map