Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EnsureParentDir ¶
EnsureParentDir creates parent directories for the given path if they do not exist.
func FlockExclusive ¶
FlockExclusive acquires an exclusive (write) lock on the file. If nonBlocking is true, returns immediately with an error if the lock cannot be acquired.
func FlockShared ¶
FlockShared acquires a shared (read) lock on the file. If nonBlocking is true, returns immediately with an error if the lock cannot be acquired.
func ReplaceFileAtomically ¶
ReplaceFileAtomically renames tempPath to targetPath. On systems where cross-device rename fails, it falls back to remove-then-rename.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.