diff --git a/.github/workflows/codeql.yaml b/.github/workflows/codeql.yaml index df320ce9b9..c86f06e2a1 100644 --- a/.github/workflows/codeql.yaml +++ b/.github/workflows/codeql.yaml @@ -2,10 +2,14 @@ name: "Code Scanning - Action" on: push: - branches: [ master ] + branches: + - master + - main pull_request: # The branches below must be a subset of the branches above - branches: [ master ] + branches: + - master + - main schedule: - cron: '0 17 * * 5' diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 8fa6e7af5f..2c17a13f28 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,9 +1,13 @@ name: "build-and-test" on: # rebuild any PRs and main branch changes pull_request: + branches: + - master + - main push: branches: - master + - main - "releases/*" jobs: @@ -53,8 +57,8 @@ jobs: version: - "" - "latest" - - "v1.60" - - "v1.60.1" + - "v1.60" # TODO(ldez): it should be updated for v2. + - "v1.60.1" # TODO(ldez): it should be updated for v2. runs-on: ${{ matrix.os }} permissions: contents: read @@ -82,8 +86,8 @@ jobs: version: - "" - "latest" - - "v1.60.1" - - "adbdfdb288e939a175182b7a12b7555215ce98b2" + - "v1.60.1" # TODO(ldez): it should be updated for v2. + - "adbdfdb288e939a175182b7a12b7555215ce98b2" # TODO(ldez): it should be updated for v2. runs-on: ${{ matrix.os }} permissions: contents: read diff --git a/src/install.ts b/src/install.ts index 28929c9888..22935082e5 100644 --- a/src/install.ts +++ b/src/install.ts @@ -91,12 +91,14 @@ export async function goInstall(versionConfig: VersionConfig): Promise { const options: ExecOptions = { env: { ...process.env, CGO_ENABLED: "1" } } + // TODO(ldez): it should be updated for v2. const exres = await execShellCommand( `go install github.com/golangci/golangci-lint/cmd/golangci-lint@${versionConfig.TargetVersion}`, options ) printOutput(exres) + // TODO(ldez): it should be updated for v2. const res = await execShellCommand( `go install -n github.com/golangci/golangci-lint/cmd/golangci-lint@${versionConfig.TargetVersion}`, options diff --git a/src/version.ts b/src/version.ts index 32ba1839ab..03e1a6d8bf 100644 --- a/src/version.ts +++ b/src/version.ts @@ -135,7 +135,8 @@ export async function findLintVersion(mode: InstallMode): Promise if (mode == InstallMode.GoInstall) { const v: string = core.getInput(`version`) - // TODO(ldez): latest should be replaced with an explicit version (ex: v1.64.0) + // TODO(ldez): latest should be replaced with an explicit version (ex: v1.64.0). + // TODO(ldez): AssetURL should be updated for v2. return { TargetVersion: v ? v : "latest", AssetURL: "github.com/golangci/golangci-lint" } }