Skip to content

Commit 4f4cfb7

Browse files
authored
Merge pull request #69 from codacy/resume-releases
breaking: Resume CLI releases
2 parents ce36811 + 4552dc6 commit 4f4cfb7

File tree

2 files changed

+36
-28
lines changed

2 files changed

+36
-28
lines changed

.github/workflows/go.yml

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -94,31 +94,31 @@ jobs:
9494
# Write-Host "Attempting to run CLI..."
9595
# .\cli-v2.exe install
9696

97-
## For now we are not releasing the CLI, as we are making some quicker iterations
98-
# release:
99-
# needs: [test, ittest]
100-
# if: github.ref == format('refs/heads/{0}', github.event.repository.default_branch) && github.event_name == 'push'
101-
# runs-on: ubuntu-latest
102-
# steps:
103-
# - name: Checkout
104-
# uses: actions/checkout@v4
105-
# with:
106-
# fetch-depth: 0
107-
# - name: Set up Go
108-
# uses: actions/setup-go@v4
109-
# - name: "Git Version"
110-
# id: generate-version
111-
# uses: codacy/[email protected]
112-
# - name: "Tag version"
113-
# run: |
114-
# git tag ${{ steps.generate-version.outputs.version }}
115-
# git push --tags "https://codacy:${{ secrets.GITHUB_TOKEN }}@github.com/codacy/codacy-cli-v2"
116-
# - name: Run GoReleaser
117-
# uses: goreleaser/goreleaser-action@v5
118-
# with:
119-
# distribution: goreleaser
120-
# # 'latest', 'nightly', or a semver
121-
# version: "latest"
122-
# args: release --clean
123-
# env:
124-
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
97+
# For now we are not releasing the CLI, as we are making some quicker iterations
98+
release:
99+
needs: [test, ittest]
100+
if: github.ref == format('refs/heads/{0}', github.event.repository.default_branch) && github.event_name == 'push'
101+
runs-on: ubuntu-latest
102+
steps:
103+
- name: Checkout
104+
uses: actions/checkout@v4
105+
with:
106+
fetch-depth: 0
107+
- name: Set up Go
108+
uses: actions/setup-go@v4
109+
- name: "Git Version"
110+
id: generate-version
111+
uses: codacy/[email protected]
112+
- name: "Tag version"
113+
run: |
114+
git tag ${{ steps.generate-version.outputs.version }}
115+
git push --tags "https://codacy:${{ secrets.GITHUB_TOKEN }}@github.com/codacy/codacy-cli-v2"
116+
- name: Run GoReleaser
117+
uses: goreleaser/goreleaser-action@v5
118+
with:
119+
distribution: goreleaser
120+
# 'latest', 'nightly', or a semver
121+
version: "latest"
122+
args: release --clean
123+
env:
124+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,14 @@ To upload a SARIF file to Codacy:
9494
codacy-cli upload -s path/to/your.sarif -c your-commit-uuid -t your-project-token
9595
```
9696

97+
## Breaking Changes
98+
99+
Some behaviors have changed with the new updates of the CLI. To rely on a specific version, you can add that version to your environment:
100+
101+
```
102+
export CODACY_CLI_V2_VERSION="1.0.0-main.133.3607792"
103+
```
104+
97105
### Example Repository
98106

99107
As an example, you can check https://github.com/troubleshoot-codacy/eslint-test-examples for a repository that has an action relying on this CLI.

0 commit comments

Comments
 (0)