mirror of
https://github.com/XTLS/Xray-core.git
synced 2024-11-22 00:21:29 +00:00
Fix vformat
This commit is contained in:
parent
5f3949a838
commit
778992eeb9
|
@ -1,4 +1,5 @@
|
||||||
package core
|
package core
|
||||||
|
|
||||||
//go:generate go install -v github.com/daixiang0/gci@latest
|
//go:generate go install -v github.com/daixiang0/gci@latest
|
||||||
|
//go:generate go install -v mvdan.cc/gofumpt@latest
|
||||||
//go:generate go run ../infra/vformat/main.go -pwd ./..
|
//go:generate go run ../infra/vformat/main.go -pwd ./..
|
||||||
|
|
|
@ -134,7 +134,7 @@ func main() {
|
||||||
if runtime.GOOS == "windows" {
|
if runtime.GOOS == "windows" {
|
||||||
suffix = ".exe"
|
suffix = ".exe"
|
||||||
}
|
}
|
||||||
gofmt := "gofmt" + suffix
|
gofmt := "gofumpt" + suffix
|
||||||
goimports := "gci" + suffix
|
goimports := "gci" + suffix
|
||||||
|
|
||||||
if gofmtPath, err := exec.LookPath(gofmt); err != nil {
|
if gofmtPath, err := exec.LookPath(gofmt); err != nil {
|
||||||
|
@ -183,8 +183,7 @@ func main() {
|
||||||
}
|
}
|
||||||
|
|
||||||
goimportsArgs := []string{
|
goimportsArgs := []string{
|
||||||
"-w",
|
"write",
|
||||||
"-local", "github.com/xtls/xray-core",
|
|
||||||
}
|
}
|
||||||
|
|
||||||
RunMany(gofmt, gofmtArgs, rawFilesSlice)
|
RunMany(gofmt, gofmtArgs, rawFilesSlice)
|
||||||
|
|
Loading…
Reference in a new issue