Skip to content

Commit

Permalink
fix: invalid filepath in the setup cmd on windows (#468)
Browse files Browse the repository at this point in the history
Signed-off-by: rick <[email protected]>
Co-authored-by: rick <[email protected]>
  • Loading branch information
LinuxSuRen and LinuxSuRen authored Mar 29, 2024
1 parent 5178993 commit 016a1cb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkg/installer/check.go
Original file line number Diff line number Diff line change
Expand Up @@ -568,7 +568,8 @@ type proxyServer struct {

// GetProxyServers returns the proxy servers
func GetProxyServers() []string {
configFile := sysos.ExpandEnv("$HOME/.config/hd-home/proxy.yaml")
home, _ := homedir.Dir()
configFile := filepath.Join(home, ".config/hd-home/proxy.yaml")
data, err := sysos.ReadFile(configFile)
if err == nil {
proxyServer := &proxyServer{}
Expand Down

0 comments on commit 016a1cb

Please sign in to comment.