package
Version:
v0.3.2
Opens a new window with list of versions in this module.
Published: Nov 15, 2026
License: AGPL-3.0
Opens a new window with license information.
Imports: 2
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
Package fsutil 提供落盘一致性工具:同目录临时文件 → 写入 → fsync → rename,
保证目标文件不会出现「写了一半」的中间态(被进程/掉电打断时要么是旧内容,要么是新内容)。
CopyFile 把 src 复制到 dst,原子替换并显式指定权限。
临时文件与目标同目录(保证 rename 不跨文件系统);失败时清理临时文件、不动 dst。
Source Files
¶
Click to show internal directories.
Click to hide internal directories.