Skip to content

Commit

Permalink
Update go.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
pkujhd authored Feb 21, 2025
1 parent 4037c03 commit 8002c32
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ jobs:
shell: sh
run: |
if [ ${{ matrix.go-second-version }} -ge 20 ]; then
go list -export -f '{{if .Export}}packagefile {{.ImportPath}}={{.Export}}{{end}}' std `go list -f {{.Imports}} $GOPATH/src/github.com/pkujhd/goloader/examples/const/const.go | awk '{sub(/^\[/, ""); print }' | awk '{sub(/\]$/, ""); print }'` > importcfg
go list -export -deps -f '{{if .Export}}packagefile {{.ImportPath}}={{.Export}}{{end}}' $GOPATH/src/github.com/pkujhd/goloader/examples/const/const.go > importcfg
go tool compile -importcfg importcfg $GOPATH/src/github.com/pkujhd/goloader/examples/const/const.go
else
go tool compile $GOPATH/src/github.com/pkujhd/goloader/examples/const/const.go
Expand All @@ -74,7 +74,7 @@ jobs:
shell: sh
run: |
if [ ${{ matrix.go-second-version }} -ge 20 ]; then
go list -export -f '{{if .Export}}packagefile {{.ImportPath}}={{.Export}}{{end}}' std `go list -f {{.Imports}} $GOPATH/src/github.com/pkujhd/goloader/examples/base/base.go | awk '{sub(/^\[/, ""); print }' | awk '{sub(/\]$/, ""); print }'` > importcfg
go list -export -deps -f '{{if .Export}}packagefile {{.ImportPath}}={{.Export}}{{end}}' $GOPATH/src/github.com/pkujhd/goloader/examples/base/base.go > importcfg
go tool compile -importcfg importcfg $GOPATH/src/github.com/pkujhd/goloader/examples/base/base.go
else
go tool compile $GOPATH/src/github.com/pkujhd/goloader/examples/base/base.go
Expand Down

0 comments on commit 8002c32

Please sign in to comment.