Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DeleteFile ¶
DeleteFile will delete filepath permanently. Returns an error in case there's any.
func GetFile ¶
GetFile will open filepath. Returns a tuple with a file and an error in case there's any.
func SafeReadTomlFile ¶
SafeReadTomlFile will try to acquire a lock on the file and then read its content afterwards. Returns an error in case there's any.
func SafeWriteTomlFile ¶
SafeWriteTomlFile will try to acquire a lock on the file and then write to it. Returns an error in case there's any.
Types ¶
type FileMutex ¶
type FileMutex struct {
// contains filtered or unexported fields
}
FileMutex is a wrapper used to create lock on files.
func MakeFileMutex ¶
MakeFileMutex will create a FileMutex intance. Returns a FileMutex instance.
Click to show internal directories.
Click to hide internal directories.