v0.0.5 - 更新请求实现方式

This commit is contained in:
spiritlhl
2024-07-02 02:10:26 +00:00
parent 16426cb85f
commit 8f4ff3ee3a
10 changed files with 105 additions and 54 deletions

View File

@@ -7,15 +7,6 @@ import (
"github.com/oneclickvirt/basics/model"
)
func isMacOS() bool {
out, err := exec.Command("uname", "-a").Output()
if err != nil {
return false
}
systemName := strings.ToLower(string(out))
return strings.Contains(systemName, "darwin")
}
func getMacOSInfo() {
out, err := exec.Command("system_profiler", "SPHardwareDataType").Output()
if err == nil && !strings.Contains(string(out), "error") {