Skip to content

Commit

Permalink
actions: use go-version-file: .go-version
Browse files Browse the repository at this point in the history
  • Loading branch information
v1v committed Nov 30, 2022
1 parent 7b45320 commit 9b8dae9
Show file tree
Hide file tree
Showing 33 changed files with 33 additions and 102 deletions.
4 changes: 1 addition & 3 deletions .github/workflows/check-audtibeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Run check/update
run: |
go install github.com/magefile/mage
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-default.yml
Expand Up @@ -17,11 +17,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Run check-default
run: |
go install github.com/magefile/mage
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-dev-tools.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Run check/update
run: |
go install github.com/magefile/mage
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-docs.yml
Expand Up @@ -17,11 +17,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Install libpcap-dev
run: sudo apt-get install -y libpcap-dev
- name: Install libsystemd-dev
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-filebeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Install libsystemd-dev
run: sudo apt-get install -y libsystemd-dev
- name: Run check/update
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-heartbeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Run check/update
run: |
go install github.com/magefile/mage
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-libbeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Install libpcap-dev
run: sudo apt-get install -y libpcap-dev
- name: Run check/update
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-metricbeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Run check/update
run: |
go install github.com/magefile/mage
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-packetbeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Install libpcap-dev
run: sudo apt-get install -y libpcap-dev
- name: Run check/update
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-winlogbeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Run check/update
run: |
go install github.com/magefile/mage
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-xpack-auditbeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Install librpm-dev
run: sudo apt-get install -y librpm-dev
- name: Run check/update
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-xpack-dockerlogbeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Run check/update
run: |
go install github.com/magefile/mage
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-xpack-filebeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Install libpcap-dev
run: sudo apt-get install -y libpcap-dev
- name: Run check/update
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-xpack-functionbeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Run check/update
run: |
go install github.com/magefile/mage
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-xpack-heartbeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Run check/update
run: |
go install github.com/magefile/mage
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-xpack-libbeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Run check/update
run: |
go install github.com/magefile/mage
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-xpack-metricbeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Run check/update
run: |
go install github.com/magefile/mage
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-xpack-osquerybeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Run check/update
run: |
go install github.com/magefile/mage
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-xpack-packetbeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Install libpcap-dev
run: sudo apt-get install -y libpcap-dev
- name: Run check/update
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/check-xpack-winlogbeat.yml
Expand Up @@ -15,11 +15,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- name: Run check/update
uses: magefile/mage-action@v2
with:
Expand Down
7 changes: 1 addition & 6 deletions .github/workflows/golangci-lint.yml
Expand Up @@ -28,14 +28,9 @@ jobs:

- uses: actions/checkout@v3

# Uses Go version from the repository.
- name: Read .go-version file
id: goversion
run: echo "::set-output name=version::$(cat .go-version)"

- uses: actions/setup-go@v3
with:
go-version: "${{ steps.goversion.outputs.version }}"
go-version-file: .go-version

- name: golangci-lint
env:
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/macos-auditbeat.yml
Expand Up @@ -18,11 +18,9 @@ jobs:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- uses: actions/setup-python@v4
with:
python-version: '3.9'
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/macos-filebeat.yml
Expand Up @@ -18,11 +18,9 @@ jobs:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- uses: actions/setup-python@v4
with:
python-version: '3.9'
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/macos-heartbeat.yml
Expand Up @@ -18,11 +18,9 @@ jobs:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- uses: actions/setup-python@v4
with:
python-version: '3.9'
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/macos-metricbeat.yml
Expand Up @@ -18,11 +18,9 @@ jobs:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- uses: actions/setup-python@v4
with:
python-version: '3.9'
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/macos-packetbeat.yml
Expand Up @@ -18,11 +18,9 @@ jobs:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- uses: actions/setup-python@v4
with:
python-version: '3.9'
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/macos-xpack-auditbeat.yml
Expand Up @@ -18,11 +18,9 @@ jobs:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- uses: actions/setup-python@v4
with:
python-version: '3.9'
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/macos-xpack-filebeat.yml
Expand Up @@ -18,11 +18,9 @@ jobs:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- uses: actions/setup-python@v4
with:
python-version: '3.9'
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/macos-xpack-functionbeat.yml
Expand Up @@ -18,11 +18,9 @@ jobs:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- uses: actions/setup-python@v4
with:
python-version: '3.9'
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/macos-xpack-heartbeat.yml
Expand Up @@ -18,11 +18,9 @@ jobs:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
go-version-file: .go-version
- uses: actions/setup-python@v4
with:
python-version: '3.9'
Expand Down

0 comments on commit 9b8dae9

Please sign in to comment.