mirror of
https://github.com/netchx/netch.git
synced 2026-03-14 17:43:18 +08:00
Update scripts and fix build
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
$exec=(Split-Path $MyInvocation.MyCommand.Path -Parent)
|
||||
$last=(Get-Location).Path
|
||||
|
||||
Set-Location $exec
|
||||
Push-Location $exec
|
||||
|
||||
$Env:CGO_ENABLED="0"
|
||||
$Env:GOROOT_FINAL="/usr"
|
||||
@@ -10,5 +9,5 @@ $Env:GOOS="windows"
|
||||
$Env:GOARCH="amd64"
|
||||
go build -a -trimpath -asmflags "-s -w" -ldflags "-s -w" -o "..\release\tun2socks.exe"
|
||||
|
||||
Set-Location $last
|
||||
Pop-Location
|
||||
exit $lastExitCode
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
$exec=(Split-Path $MyInvocation.MyCommand.Path -Parent)
|
||||
$last=(Get-Location).Path
|
||||
|
||||
Set-Location $exec
|
||||
Push-Location $exec
|
||||
|
||||
rm -Force go.*
|
||||
go mod init tun2socks
|
||||
go mod tidy
|
||||
|
||||
Set-Location $last
|
||||
Pop-Location
|
||||
exit $lastExitCode
|
||||
|
||||
Reference in New Issue
Block a user