From: qydysky <32743305+qydysky@users.noreply.github.com> Date: Sun, 4 Oct 2020 10:15:17 +0000 (+0800) Subject: Create go.yml X-Git-Tag: v0.0.0~1 X-Git-Url: http://127.0.0.1:8081/?a=commitdiff_plain;h=4f12dd366d676b767e0487e5b999794dbc073605;p=bili_danmu%2F.git Create go.yml --- diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml new file mode 100644 index 0000000..20e2e5d --- /dev/null +++ b/.github/workflows/go.yml @@ -0,0 +1,42 @@ +name: Go + +on: + release: + types: [released,prereleased] + branches: + - master + +jobs: + + build: + name: Build + runs-on: ubuntu-latest + steps: + + - name: Set up Go 1.x + uses: actions/setup-go@v2 + with: + go-version: ^1.15.2 + id: go + + - name: Check out code into the Go module directory + uses: actions/checkout@v2 + + - name: Get dependencies + run: | + go get -v -t -d ./... + if [ -f Gopkg.toml ]; then + curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh + dep ensure + fi + + - name: Build + run: go build -v . + + - name: Upload a Build Artifact + uses: actions/upload-artifact@v2.2.0 + with: + # Artifact name + # A file, directory or wildcard pattern that describes what to upload + path: ./ + # The desired behavior if no files are found using the provided path.