Update sourcery.yml #4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Sourcery Analysis | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
sourcery: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Set up Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: '20' # Specify the Node.js version you are using | |
- name: Install dependencies | |
run: | | |
npm install | |
#- name: Install Sourcery | |
#run: | | |
#npm install -g sourcery-cli | |
- name: Run Sourcery | |
env: | |
SOURCERY_API_TOKEN: ${{ secrets.SOURCERY_API_TOKEN }} | |
run: | | |
sourcery review . | |
- name: Upload Sourcery Review Report | |
if: always() | |
uses: actions/upload-artifact@v2 | |
with: | |
name: sourcery-report | |
path: sourcery_report.json | |
- name: Post Comment with Results | |
if: always() | |
uses: peter-evans/create-or-update-comment@v2 | |
with: | |
issue-number: ${{ github.event.pull_request.number }} | |
body: | | |
## Sourcery Analysis Results | |
[View the report](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}) |