Skip to content

Reviewing gitrey's code changes πŸš€ #195

Reviewing gitrey's code changes πŸš€

Reviewing gitrey's code changes πŸš€ #195

Workflow file for this run

# AI enabled code reviews using devai
# - Requires GCP service account stored in GOOGLE_API_CREDENTIALS secret
name: GenAI For Developers
run-name: Reviewing ${{ github.actor }}'s code changes πŸš€
on: [workflow_dispatch]
env:
LOCATION: us-central1
PROJECT_ID: '${{ secrets.PROJECT_ID }}'
JIRA_CLOUD: true
# Following environment variables need to be configured if GitHub integration/commands
# to automatically open pull requests are enabled
# see docs/tutorials/setup-github.md for more details
GITHUB_APP_ID: '${{ secrets.GH_APP_ID }}'
GITHUB_REPOSITORY: '${{ secrets.GH_REPOSITORY }}'
GITHUB_APP_PRIVATE_KEY: '${{ secrets.GH_APP_PRIVATE_KEY }}'
jobs:
DevAI-Reviews:
runs-on: ubuntu-latest
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: List files in the repository
run: |
ls ${{ github.workspace }}
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11.7'
- run: cd ${{ github.workspace }}/devai-cli
- run: pip install virtualenv
- run: virtualenv venv
- run: source venv/bin/activate
- run: pip install -r ${{ github.workspace }}/devai-cli/src/requirements.txt
- run: pip install --editable ${{ github.workspace }}/devai-cli/src
- name: Authorize. with GCP
uses: 'google-github-actions/auth@v2'
with:
credentials_json: '${{ secrets.GOOGLE_API_CREDENTIALS }}'
project_id: '${{ secrets.PROJECT_ID }}'
# - name: Docs update with PR
# run: echo '## Docs Update Results πŸš€' >> $GITHUB_STEP_SUMMARY
# - run: echo "$(devai document readme -c ${{ github.workspace }}/sample-app/src -f 'sample-app/README.md' -b 'feature/docs-update')" >> $GITHUB_STEP_SUMMARY
# shell: bash
- name: Test Coverage Review
run: echo '## Test Coverage Review Results πŸš€' >> $GITHUB_STEP_SUMMARY
- run: echo "$(devai review testcoverage -c ${{ github.workspace }}/sample-app/src)" >> $GITHUB_STEP_SUMMARY
shell: bash
- name: Code Review
run: echo '## Code Review Results πŸš€' >> $GITHUB_STEP_SUMMARY
- run: echo "$(devai review code -c ${{ github.workspace }}/sample-app/src/main/java/anthos/samples/bankofanthos/balancereader)" >> $GITHUB_STEP_SUMMARY
shell: bash
- name: Performance Review
run: echo '## Performance Review Results πŸš€' >> $GITHUB_STEP_SUMMARY
- run: echo "$(devai review performance -c ${{ github.workspace }}/sample-app/src/main/java/anthos/samples/bankofanthos/balancereader)" >> $GITHUB_STEP_SUMMARY
shell: bash
- name: Security Review
run: echo '## Security Review Results πŸš€' >> $GITHUB_STEP_SUMMARY
- run: echo "$(devai review security -c ${{ github.workspace }}/sample-app/src/main/java/anthos/samples/bankofanthos/balancereader)" >> $GITHUB_STEP_SUMMARY
shell: bash
- name: Blockers Review
run: echo '## Blockers Review Results πŸš€' >> $GITHUB_STEP_SUMMARY
- run: echo "$(devai review blockers -c ${{ github.workspace }}/sample-app/pom.xml)" >> $GITHUB_STEP_SUMMARY
shell: bash