mirror of
https://github.com/rwinkhart/rcw.git
synced 2026-08-28 04:46:42 -04:00
13 lines
202 B
Go
13 lines
202 B
Go
package daemon
|
|
|
|
import "os"
|
|
|
|
func daemonIsOpen() bool {
|
|
// check if socketPath exists and is a file
|
|
fileInfo, err := os.Stat(socketPath)
|
|
if err != nil {
|
|
return false
|
|
}
|
|
return !fileInfo.IsDir()
|
|
}
|