diff --git a/.github/workflows/update_singbox_core.yaml b/.github/workflows/update_singbox_core.yaml index 2583842..b27cc70 100644 --- a/.github/workflows/update_singbox_core.yaml +++ b/.github/workflows/update_singbox_core.yaml @@ -118,6 +118,7 @@ jobs: GOARM: ${{ matrix.goarm }} GOMIPS: ${{ matrix.gomips }} CGO_ENABLED: 0 + REPO: ${{ github.event.inputs.tag1 }} TAGS: ${{needs.sing-box.outputs.tags}} VERSION: ${{needs.sing-box.outputs.version}} steps: @@ -133,6 +134,18 @@ jobs: with: go-version: ${{ steps.go.outputs.version }} + - name: checkout sing repository + if: ${{ env.REPO == 'PuerNya/sing-box' }} + uses: actions/checkout@v4.1.1 + with: + ref: fix-interface + path: sing + repository: PuerNya/sing + + - name: replace sing + if: ${{ env.REPO == 'PuerNya/sing-box' }} + run: sed -i 's/^\/\/replace github.com.*$/replace github.com\/sagernet\/sing => .\/sing/' go.mod + - name: build core id: build run: go build -v -trimpath -ldflags "-X 'github.com/sagernet/sing-box/constant.Version=${VERSION}' -s -w -buildid=" -tags "${TAGS}" ./cmd/sing-box