Skip to content

Commit

Permalink
Merge pull request #597 from rstudio/do-not-post-results-to-PR
Browse files Browse the repository at this point in the history
Do not post results to the PR.  Without better sanitization of that o…
  • Loading branch information
jforest authored Oct 28, 2024
2 parents 6984a9e + 2905e47 commit 24867fb
Showing 1 changed file with 1 addition and 19 deletions.
20 changes: 1 addition & 19 deletions .github/workflows/chart-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,7 @@ jobs:
- name: Run chart-testing (lint changed)
id: ct-lint
if: steps.list-changed.outputs.changed == 'true'
run: |
{
echo 'result<<EOF'
ct lint --target-branch main --chart-dirs charts --chart-dirs other-charts
echo 'EOF'
} >> $GITHUB_OUTPUT
run: ct lint --target-branch main --chart-dirs charts --chart-dirs other-charts
continue-on-error: true

- name: Run chart-testing (lint all)
Expand Down Expand Up @@ -80,19 +75,6 @@ jobs:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
SLACK_WEBHOOK_TYPE: INCOMING_WEBHOOK

- name: Add linting results for changed charts to PR
if: github.event_name == 'pull_request' && steps.list-changed.outputs.changed == 'true'
uses: actions/github-script@v7
with:
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: `${{steps.ct-lint.outputs.result}}`
})
- name: Fail the workflow if failed linting
if: steps.ct-lint.outcome == 'failure' || steps.ct-lint-all.outcome == 'failure'
run: exit 1
Expand Down

0 comments on commit 24867fb

Please sign in to comment.