-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Initial commit based on the content of the GitHub autograding action.
- Loading branch information
0 parents
commit 6e40cb2
Showing
40 changed files
with
5,476 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
addReviewers: false | ||
addAssignees: true | ||
|
||
assignees: | ||
- uhafner | ||
|
||
skipKeywords: | ||
- wip | ||
|
||
numberOfAssignees: 0 |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
version: 2 | ||
updates: | ||
- package-ecosystem: maven | ||
directory: "/" | ||
schedule: | ||
interval: daily | ||
open-pull-requests-limit: 10 | ||
commit-message: | ||
prefix: "" | ||
ignore: | ||
- dependency-name: org.eclipse.collections:eclipse-collections | ||
versions: | ||
- ">= 10.a" | ||
- dependency-name: org.eclipse.collections:eclipse-collections-api | ||
versions: | ||
- ">= 10.a" | ||
- dependency-name: net.javacrumbs.json-unit:json-unit-assertj | ||
versions: | ||
- ">= 3.0.0" | ||
|
||
- package-ecosystem: "github-actions" | ||
directory: "/" | ||
commit-message: | ||
prefix: "" | ||
schedule: | ||
interval: "daily" | ||
|
||
- package-ecosystem: "npm" | ||
directory: "/" | ||
commit-message: | ||
prefix: "" | ||
schedule: | ||
interval: "daily" |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
- name: bug | ||
description: Bugs or performance problems | ||
color: CC0000 | ||
- name: dependencies | ||
description: Update of dependencies | ||
color: 0366d6 | ||
- name: feature | ||
color: a4c6fb | ||
description: New features | ||
- name: enhancement | ||
description: Enhancement of existing functionality | ||
color: 94a6eb | ||
- name: deprecated | ||
description: Deprecating API | ||
color: f4c21d | ||
- name: removed | ||
description: Removing API | ||
color: e4b21d | ||
- name: tests | ||
description: Enhancement of tests | ||
color: 30cc62 | ||
- name: documentation | ||
description: Enhancement of documentation | ||
color: bfafea | ||
- name: internal | ||
description: Internal changes without user or API impact | ||
color: e6e6e6 |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
name-template: 'v$RESOLVED_VERSION 🎁' | ||
tag-template: 'v$RESOLVED_VERSION' | ||
|
||
template: | | ||
$CHANGES | ||
# Emoji reference: https://gitmoji.carloscuesta.me/ | ||
categories: | ||
- title: 💥 Removed | ||
label: removed | ||
- title: ⚠️ Deprecated | ||
label: deprecated | ||
- title: 🚀 New features | ||
labels: | ||
- feature | ||
- title: ✨ Improvements | ||
labels: | ||
- enhancement | ||
- title: 🐛 Bug Fixes | ||
labels: | ||
- bug | ||
- fix | ||
- bugfix | ||
- regression | ||
- title: 📝 Documentation updates | ||
label: documentation | ||
- title: 📦 Dependency updates | ||
label: dependencies | ||
- title: 🔧 Internal changes | ||
label: internal | ||
- title: 🚦 Tests | ||
labels: | ||
- test | ||
- tests | ||
|
||
version-resolver: | ||
major: | ||
labels: | ||
- 'removed' | ||
minor: | ||
labels: | ||
- 'feature' | ||
- 'enhancement' | ||
- 'deprecated' | ||
patch: | ||
labels: | ||
- 'dependencies' | ||
- 'documentation' | ||
- 'tests' | ||
- 'internal' | ||
default: minor |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
name: 'Auto Assign PR' | ||
|
||
on: pull_request_target | ||
|
||
jobs: | ||
assign-pr: | ||
name: 'Auto Assign PR' | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: kentaro-m/auto-assign-action@v1.2.5 | ||
with: | ||
repo-token: "${{ secrets.GITHUB_TOKEN }}" |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,124 @@ | ||
name: 'Autograding PR' | ||
|
||
on: | ||
pull_request: | ||
|
||
jobs: | ||
build: | ||
|
||
runs-on: [ubuntu-latest] | ||
name: Build, test and autograde on Ubuntu | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up JDK 21 | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: 'temurin' | ||
java-version: 21 | ||
check-latest: true | ||
cache: 'maven' | ||
- name: Set up Maven | ||
uses: stCarolas/setup-maven@v4.5 | ||
with: | ||
maven-version: 3.9.5 | ||
- name: Build with Maven | ||
env: | ||
BROWSER: chrome-container | ||
run: mvn -V --color always -ntp clean verify --file pom.xml '-Djenkins.test.timeout=5000' '-Dgpg.skip' -Ppit | tee maven.log | ||
- name: Extract pull request number | ||
uses: jwalton/gh-find-current-pr@v1 | ||
id: pr | ||
- name: Run Autograding | ||
uses: uhafner/autograding-github-action@v3 | ||
with: | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
pr-number: ${{ steps.pr.outputs.number }} | ||
checks-name: 'Quality Checks' | ||
config: > | ||
{ | ||
"tests": { | ||
"tools": [ | ||
{ | ||
"id": "test", | ||
"name": "Unittests", | ||
"pattern": "**/target/*-reports/TEST*.xml" | ||
} | ||
], | ||
"name": "JUnit", | ||
"passedImpact": 0, | ||
"skippedImpact": -1, | ||
"failureImpact": -5, | ||
"maxScore": 100 | ||
}, | ||
"analysis": { | ||
"name": "Warnings", | ||
"id": "warnings", | ||
"tools": [ | ||
{ | ||
"id": "checkstyle", | ||
"name": "CheckStyle", | ||
"pattern": "**/target/checkstyle-result.xml" | ||
}, | ||
{ | ||
"id": "pmd", | ||
"name": "PMD", | ||
"pattern": "**/target/pmd.xml" | ||
}, | ||
{ | ||
"id": "error-prone", | ||
"name": "Error Prone", | ||
"pattern": "**/maven.log" | ||
}, | ||
{ | ||
"id": "spotbugs", | ||
"name": "SpotBugs", | ||
"sourcePath": "src/main/java", | ||
"pattern": "**/target/spotbugsXml.xml" | ||
} | ||
], | ||
"errorImpact": -1, | ||
"highImpact": -1, | ||
"normalImpact": -1, | ||
"lowImpact": -1, | ||
"maxScore": 100 | ||
}, | ||
"coverage": [ | ||
{ | ||
"tools": [ | ||
{ | ||
"id": "jacoco", | ||
"name": "Line Coverage", | ||
"metric": "line", | ||
"sourcePath": "src/main/java", | ||
"pattern": "**/target/site/jacoco/jacoco.xml" | ||
}, | ||
{ | ||
"id": "jacoco", | ||
"name": "Branch Coverage", | ||
"metric": "branch", | ||
"sourcePath": "src/main/java", | ||
"pattern": "**/target/site/jacoco/jacoco.xml" | ||
} | ||
], | ||
"name": "JaCoCo", | ||
"maxScore": 100, | ||
"missedPercentageImpact": -1 | ||
}, | ||
{ | ||
"tools": [ | ||
{ | ||
"id": "pit", | ||
"name": "Mutation Coverage", | ||
"metric": "mutation", | ||
"sourcePath": "src/main/java", | ||
"pattern": "**/target/pit-reports/mutations.xml" | ||
} | ||
], | ||
"name": "PIT", | ||
"maxScore": 100, | ||
"missedPercentageImpact": -1 | ||
} | ||
] | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
name: CD | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
build: | ||
name: Build and deploy to Docker hub | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up JDK 21 | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: 'temurin' | ||
java-version: '21' | ||
check-latest: true | ||
cache: 'maven' | ||
- name: Set up Maven | ||
uses: stCarolas/setup-maven@v4.5 | ||
with: | ||
maven-version: 3.9.5 | ||
- name: Build and deploy | ||
env: | ||
DOCKER_IO_USERNAME: ${{ secrets.DOCKER_IO_USERNAME }} | ||
DOCKER_IO_PASSWORD: ${{ secrets.DOCKER_IO_PASSWORD }} | ||
run: mvn -ntp clean install |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
name: "CodeQL" | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
- main | ||
pull_request: | ||
branches: | ||
- master | ||
- main | ||
schedule: | ||
- cron: "32 3 * * 0" | ||
|
||
jobs: | ||
analyze: | ||
name: Analyze with CodeQL | ||
runs-on: ubuntu-latest | ||
permissions: | ||
actions: read | ||
contents: read | ||
security-events: write | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
language: [ java ] | ||
|
||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Setup Java | ||
uses: actions/setup-java@v4 | ||
with: | ||
distribution: temurin | ||
java-version: 21 | ||
cache: maven | ||
|
||
- name: Set up Maven | ||
uses: stCarolas/setup-maven@v4.5 | ||
with: | ||
maven-version: 3.9.6 | ||
|
||
- name: Initialize CodeQL | ||
uses: github/codeql-action/init@v3 | ||
with: | ||
languages: ${{ matrix.language }} | ||
queries: +security-and-quality | ||
|
||
- name: Build with Maven | ||
run: mvn -V --color always -ntp clean verify --file pom.xml -Pskip | ||
|
||
- name: Perform CodeQL Analysis | ||
uses: github/codeql-action/analyze@v3 | ||
with: | ||
upload: false | ||
output: sarif-results | ||
category: "/language:${{ matrix.language }}" | ||
|
||
- name: Filter SARIF results | ||
uses: advanced-security/filter-sarif@v1 | ||
with: | ||
patterns: | | ||
-**/*Assert* | ||
input: sarif-results/${{ matrix.language }}.sarif | ||
output: sarif-results/${{ matrix.language }}.sarif | ||
|
||
- name: Upload SARIF results | ||
uses: github/codeql-action/upload-sarif@v3 | ||
with: | ||
sarif_file: sarif-results/${{ matrix.language }}.sarif |
Oops, something went wrong.