Add rAudio detection and MPD playback support
This commit is contained in:
6 files changed
+96
No files matched your search
@@ -0,0 +1,17 @@
|
||||
package raudio
|
||||
|
||||
import (
|
||||
"io/fs"
|
||||
"os"
|
||||
)
|
||||
|
||||
// Detect reports whether rAudio is installed locally.
|
||||
func Detect() bool {
|
||||
return detect(os.DirFS("/"))
|
||||
}
|
||||
|
||||
func detect(root fs.FS) bool {
|
||||
// rAudio stores its core environment variables in this configuration file.
|
||||
info, err := fs.Stat(root, "srv/http/data/system/system.conf")
|
||||
return err == nil && info.Mode().IsRegular()
|
||||
}
|
||||
Reference in new issue
Block a user