push triggered by MarkPotato777 🚀 #12793
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
### | |
# This workflow is used for daily development | |
# Triggers: | |
# 1. Push | |
# 2. Pull-Request | |
# Jobs: | |
# 1. Check Code Format | |
# 2. Maven Install and PMD Scan | |
# 3. Unit Test (executed by OBFarm and triggered when Pull-Request) | |
### | |
name: Build Dev | |
run-name: ${{ github.event_name }} triggered by ${{ github.actor }} 🚀 | |
on: | |
push: | |
branches: | |
- "**" | |
pull_request: | |
branches: | |
- "**" | |
jobs: | |
check-format: | |
name: Check Code Format | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout workspace | |
uses: actions/checkout@v4 | |
- name: Setup JDK 8 | |
uses: actions/setup-java@v4 | |
with: | |
java-version: "8" | |
distribution: "temurin" | |
cache: maven | |
- name: Check code format | |
run: mvn impsort:check formatter:validate | |
- name: Check license | |
run: mvn license:check | |
pmd-scan: | |
name: PMD Scan | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout workspace | |
uses: actions/checkout@v4 | |
- name: Setup JDK 8 | |
uses: actions/setup-java@v4 | |
with: | |
java-version: "8" | |
distribution: "temurin" | |
cache: maven | |
- name: Install ob-sql-parser | |
run: | | |
echo "Start install ob-sql-parser" | |
pushd libs/ob-sql-parser | |
echo "Current dir is "`pwd` | |
mvn clean install -Dmaven.test.skip=true | |
echo "Install ob-sql-parser success" | |
popd | |
- name: Install db-browser | |
run: | | |
echo "Start install db-browser" | |
pushd libs/db-browser | |
echo "Current dir is "`pwd` | |
mvn clean install -Dmaven.test.skip=true | |
echo "Install db-browser success" | |
popd | |
- name: Install pty4j | |
run: | | |
echo "Start install pty4j" | |
pushd import | |
echo "Current dir is "`pwd` | |
mvn install:install-file -Dfile=./pty4j-0.11.4.jar -DgroupId=org.jetbrains.pty4j -DartifactId=pty4j -Dversion=0.11.4 -Dpackaging=jar | |
echo "Install pty4j success" | |
popd | |
- name: Install purejavacomm | |
run: | | |
echo "Start install purejavacomm" | |
pushd import | |
echo "Current dir is "`pwd` | |
mvn install:install-file -Dfile=./purejavacomm-0.0.11.1.jar -DgroupId=org.jetbrains.pty4j -DartifactId=purejavacomm -Dversion=0.0.11.1 -Dpackaging=jar | |
echo "Install purejavacomm success" | |
popd | |
- name: Build project | |
run: mvn clean install -Dmaven.test.skip=true | |
- name: Run PMD scan | |
run: mvn pmd:check | |
unit-test-odc: | |
name: Unit Test (ODC) | |
if: ${{ github.event_name == 'pull_request' }} | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout workspace | |
uses: actions/checkout@v4 | |
- name: action by obfarm++odc_ut++COMMIT=${{ github.event.pull_request.head.sha }} | |
uses: ./.github/obfarm/ | |
id: odc_ut | |
with: | |
pipeline_id: ${{ github.run_id }} | |
project: ${{ github.repository }} |