This repository was archived by the owner on Jul 3, 2026. It is now read-only.
adding multiple log targets support for simple game server go #312
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: simple-game-server-go | |
| on: | |
| pull_request: | |
| push: | |
| permissions: | |
| contents: write | |
| jobs: | |
| goreleaser: | |
| runs-on: ubuntu-latest | |
| defaults: | |
| run: | |
| working-directory: './simple-game-server-go' | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v2 | |
| with: | |
| fetch-depth: 0 | |
| - name: Set up Go | |
| uses: actions/setup-go@v2 | |
| with: | |
| go-version: '1.20' | |
| - name: Lint | |
| uses: golangci/golangci-lint-action@v2 | |
| with: | |
| version: v1.52.2 | |
| working-directory: './simple-game-server-go' | |
| skip-go-installation: true | |
| - name: Build | |
| uses: goreleaser/goreleaser-action@v2 | |
| if: startsWith(github.ref, 'refs/tags/') == false | |
| with: | |
| distribution: goreleaser | |
| version: v1.18.2 | |
| args: build --rm-dist --snapshot | |
| workdir: './simple-game-server-go' | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Test | |
| run: 'go test -timeout=5m -race -v ./...' | |
| - name: Login to Docker Hub | |
| uses: docker/login-action@v2 | |
| if: ${{ startsWith(github.ref, 'refs/tags/') && endsWith(github.ref, '-simple-game-server-go') }} | |
| with: | |
| username: ${{ secrets.DOCKERHUB_USERNAME }} | |
| password: ${{ secrets.DOCKERHUB_TOKEN }} | |
| - name: Release | |
| uses: goreleaser/goreleaser-action@v2 | |
| if: ${{ startsWith(github.ref, 'refs/tags/') && endsWith(github.ref, '-simple-game-server-go') }} | |
| with: | |
| distribution: goreleaser | |
| version: v1.18.2 | |
| args: release --rm-dist | |
| workdir: './simple-game-server-go' | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |