Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: adding sf.yml #500

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 0 additions & 47 deletions .github/workflows/deploy.and.test.yml

This file was deleted.

22 changes: 0 additions & 22 deletions .github/workflows/manage.sf.api.versions.yml

This file was deleted.

36 changes: 36 additions & 0 deletions .github/workflows/sf.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Salesforce Code Analyzer Workflow
on:
- push
- workflow_dispatch
jobs:
salesforce-code-analyzer-workflow:
runs-on: ubuntu-latest
steps:
- name: Check out files
uses: actions/checkout@v4

- name: Install Salesforce CLI
run: npm install -g @salesforce/cli@latest

- name: Install Salesforce Code Analyzer Plugin
run: sf plugins install @salesforce/sfdx-scanner@latest

- name: Run Salesforce Code Analyzer
id: run-code-analyzer
uses: forcedotcom/run-code-analyzer@v1
with:
run-command: run
run-arguments: --category=security --target . --format=sarif --outfile results.sarif
results-artifact-name: salesforce-code-analyzer-results

# - name: Check the outputs to determine whether to fail
# if: |
# steps.run-code-analyzer.outputs.exit-code > 0 ||
# steps.run-code-analyzer.outputs.num-sev1-violations > 0 ||
# steps.run-code-analyzer.outputs.num-violations > 10
# run: exit 1

- name: Upload SARIF file
uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: results.sarif
Loading