Skip to content

[Snyk] Upgrade oci-devops from 2.21.0 to 2.96.0 #122

[Snyk] Upgrade oci-devops from 2.21.0 to 2.96.0

[Snyk] Upgrade oci-devops from 2.21.0 to 2.96.0 #122

Workflow file for this run

name: Repolinter
on:
pull_request_target:
jobs:
run_repolinter:
name: Run Repolinter on pull request
runs-on: ubuntu-latest
container:
image: ghcr.io/oracledevrel/repolinter:v0.11.1
credentials:
username: ${{ github.actor }}
password: ${{ secrets.GHCR_PAT }}
steps:
- name: 'Checkout repo'
uses: actions/checkout@v2
with:
ref: ${{ github.event.pull_request.head.ref }}
repository: ${{ github.event.pull_request.head.repo.full_name }}
- name: Run Repolinter
run: |
set +e
bundle exec /app/bin/repolinter.js lint --format json --rulesetFile repolinter.json . > repolinter_results.json
echo "\n\nHere is the repolinter_results.json:\n"
echo $(cat repolinter_results.json)
exit 0
- name: Analyze the Repolinter results
uses: oracle-devrel/[email protected]
id: analysis
with:
json_results_file: '/github/workspace/repolinter_results.json'
- name: Overall analysis results
run: |
echo "Passed: ${{ steps.analysis.outputs.passed }}"
echo "Errored: ${{ steps.analysis.outputs.errored }}"
- name: Comment if analysis finds missing readme
if: steps.analysis.outputs.readme_file_found == 'false'
uses: mshick/add-pr-comment@v1
with:
message: |
:no_entry: **FAILURE: Missing README**
The README file seems to be missing. Please add it.
Details:
${{ steps.analysis.outputs.readme_file_details }}
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Comment if analysis finds missing license
if: steps.analysis.outputs.license_file_found == 'false'
uses: mshick/add-pr-comment@v1
with:
message: |
:no_entry: **FAILURE: Missing LICENSE**
The LICENSE file seems to be missing. Please add it.
Details:
${{ steps.analysis.outputs.license_file_details }}
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Comment if analysis finds copyright notice missing
if: steps.analysis.outputs.copyright_found == 'false'
uses: mshick/add-pr-comment@v1
with:
message: |
:warning: **WARNING: Missing Copyright Notice(s)**
It's a good idea to have copyright notices at the top of each file. It looks like at least one file was missing this (though it might be further down in the file - this might be a false-positive).
Details:
${{ steps.analysis.outputs.copyright_details }}
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Halt pipeline if README is missing
if: steps.analysis.outputs.readme_file_found == 'false'
run: exit 1
- name: Halt pipeline if LICENSE is missing
if: steps.analysis.outputs.license_file_found == 'false'
run: exit 1