mirror of
https://github.com/gravitl/netmaker.git
synced 2025-10-06 17:29:15 +08:00
fixed missing slash
This commit is contained in:
@@ -33,15 +33,20 @@ func GetServerWGConf() (models.IntClient, error) {
|
||||
func InstallNetclient() error {
|
||||
|
||||
netclientPath := ncutils.GetNetclientPath()
|
||||
if ncutils.IsWindows() {
|
||||
netclientPath += "\\"
|
||||
} else {
|
||||
netclientPath += "/"
|
||||
}
|
||||
if !FileExists(netclientPath + "netclient") {
|
||||
var err error
|
||||
if ncutils.IsWindows() {
|
||||
_, err = copy(".\\netclient\\netclient", netclientPath+"\\netclient")
|
||||
_, err = copy(".\\netclient\\netclient", netclientPath+"netclient")
|
||||
} else {
|
||||
_, err = copy("./netclient/netclient", netclientPath+"/netclient")
|
||||
_, err = copy("./netclient/netclient", netclientPath+"netclient")
|
||||
}
|
||||
if err != nil {
|
||||
log.Println("could not create " + netclientPath + "/netclient")
|
||||
log.Println("could not create " + netclientPath + "netclient")
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user