Skip to content

Add support for Project API Keys #222

Add support for Project API Keys

Add support for Project API Keys #222

Workflow file for this run

name: build
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'
- name: Setup Gradle
uses: gradle/actions/setup-gradle@v3
- name: Build
run: ./gradlew spotlessCheck build
env:
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
OPENAI_ADMIN_KEY: ${{ secrets.OPENAI_ADMIN_KEY }}
- name: Run SonarQube analysis
run: |
if [ -n "$SONAR_TOKEN" ]; then
./gradlew jacocoTestReport sonar
else
echo "SONAR_TOKEN is not set. Skipping SonarQube analysis."
fi
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}