mirror of
https://github.com/rcourtman/Pulse.git
synced 2026-12-03 18:43:38 +01:00
19 lines
287 B
Go
19 lines
287 B
Go
//go:build !windows
|
|
|
|
package agentupdate
|
|
|
|
import "os"
|
|
|
|
func replacePendingUpdateFile(from, to string) error {
|
|
return os.Rename(from, to)
|
|
}
|
|
|
|
func syncUpdateDirectory(path string) error {
|
|
dir, err := os.Open(path)
|
|
if err != nil {
|
|
return err
|
|
}
|
|
defer dir.Close()
|
|
return dir.Sync()
|
|
}
|