Skip to content

Bump github.com/spf13/cobra from 1.7.0 to 1.8.1 #198

Bump github.com/spf13/cobra from 1.7.0 to 1.8.1

Bump github.com/spf13/cobra from 1.7.0 to 1.8.1 #198

name: "Windows Go linters"
on:
push:
branches:
- main
- 7.[0-9][0-9].x
pull_request:
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
jobs:
windows-lint-go:
runs-on: windows-2019 # https://github.com/actions/virtual-environments/blob/main/images/win/Windows2019-Readme.md
steps:
- name: Checkout datadog-agent repository
uses: actions/checkout@v3
with:
fetch-depth: 0 #needed for 'git describe' to work
- name: Install python
uses: actions/setup-python@v4
with:
python-version: '3.8.10'
- name: Install go
uses: actions/setup-go@v3
with:
go-version-file: '.go-version'
- name: Set up runner
run: |
$ErrorActionPreference = 'Stop';
# install dependencies
# The Codecov Python uploader was deprecated on Feb 1, 2022 and disappeared from PyPi on Apr 12, 2023.
# python -m pip install codecov
python -m pip install -r requirements.txt
If ($lastExitCode -ne "0") { throw "Previous command returned $lastExitCode" }
inv -e install-tools
If ($lastExitCode -ne "0") { throw "Previous command returned $lastExitCode" }
inv -e deps
If ($lastExitCode -ne "0") { throw "Previous command returned $lastExitCode" }
- name: Run go linters
shell: bash # using bash so we don't have to check $lastExitCode all the time
run: |
export PATH="/c/msys64/mingw64/bin:/c/msys64/usr/bin/:$PATH" # prepend msys, otherwise make from mingw gets used
echo $PATH
powershell.exe -Command ./tasks/winbuildscripts/pre-go-build.ps1
inv -e rtloader.format --raise-if-changed
inv -e lint-go