From f9107bf05188ae3632914d1fafcbdb24c12cdfd0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0tefan=20Baebler?= Date: Sun, 7 May 2023 22:50:11 +0200 Subject: [PATCH] Workflow yaml formatting --- .github/workflows/codeql.yml | 6 +++--- .github/workflows/golangci-lint.yml | 2 +- .github/workflows/goreleaser.yml | 30 ++++++++++++++--------------- .github/workflows/test.yml | 17 ++++++++-------- 4 files changed, 27 insertions(+), 28 deletions(-) diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml index 503dbd9..2d7ce3c 100644 --- a/.github/workflows/codeql.yml +++ b/.github/workflows/codeql.yml @@ -7,9 +7,9 @@ name: "CodeQL" on: push: - branches: [ main ] + branches: [main] pull_request: - branches: [ main ] + branches: [main] workflow_dispatch: jobs: @@ -28,7 +28,7 @@ jobs: # Override automatic language detection by changing the below list # Supported options are ['csharp', 'cpp', 'go', 'java', 'javascript', 'python'] # TODO: Enable for javascript later - language: [ 'go'] + language: ["go"] steps: - name: Checkout repository diff --git a/.github/workflows/golangci-lint.yml b/.github/workflows/golangci-lint.yml index bd8963e..fdce7ca 100644 --- a/.github/workflows/golangci-lint.yml +++ b/.github/workflows/golangci-lint.yml @@ -4,7 +4,7 @@ on: branches: - main pull_request: - + permissions: contents: read # Optional: allow read access to pull request. Use with `only-new-issues` option. diff --git a/.github/workflows/goreleaser.yml b/.github/workflows/goreleaser.yml index fe4dd88..11d88f6 100644 --- a/.github/workflows/goreleaser.yml +++ b/.github/workflows/goreleaser.yml @@ -15,20 +15,20 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - with: - fetch-depth: 0 + - uses: actions/checkout@v3 + with: + fetch-depth: 0 - - name: Set up Go - uses: actions/setup-go@v4 - with: - go-version: 'stable' + - name: Set up Go + uses: actions/setup-go@v4 + with: + go-version: "stable" - - name: Build and publish - uses: goreleaser/goreleaser-action@v4 - with: - distribution: goreleaser - version: latest - args: release --clean - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + - name: Build and publish + uses: goreleaser/goreleaser-action@v4 + with: + distribution: goreleaser + version: latest + args: release --clean + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 83d6a50..514de09 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -5,21 +5,20 @@ name: Test on: push: - branches: [ "main" ] + branches: ["main"] pull_request: workflow_dispatch: jobs: - build: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v3 - - name: Set up Go - uses: actions/setup-go@v4 - with: - go-version: 1.18 + - name: Set up Go + uses: actions/setup-go@v4 + with: + go-version: 1.18 - - name: Test - run: go test -v ./... + - name: Test + run: go test -v ./...