Skip to content

Commit

Permalink
Update github action build script and POM (#54)
Browse files Browse the repository at this point in the history
* Update github action build script and POM

* Update build.yml
  • Loading branch information
tastybento authored Jan 14, 2024
1 parent 6f31a4c commit 838507c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 10 deletions.
16 changes: 8 additions & 8 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
# Build script
name: Build
name: SonarCloud
on:
push:
branches:
Expand All @@ -9,24 +8,25 @@ on:
types: [opened, synchronize, reopened]
jobs:
build:
name: Build
name: Build and analyze
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
- name: Set up JDK 17
uses: actions/setup-java@v1
uses: actions/setup-java@v3
with:
java-version: 17
distribution: 'zulu' # Alternative distribution options are available.
- name: Cache SonarCloud packages
uses: actions/cache@v1
uses: actions/cache@v3
with:
path: ~/.sonar/cache
key: ${{ runner.os }}-sonar
restore-keys: ${{ runner.os }}-sonar
- name: Cache Maven packages
uses: actions/cache@v1
uses: actions/cache@v3
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
Expand All @@ -35,4 +35,4 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
run: mvn -B verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar
run: mvn -B verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Dsonar.projectKey=BentoBoxWorld_Upgrades
3 changes: 1 addition & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
<powermock.version>2.0.9</powermock.version>

<spigot.version>1.16.5-R0.1-SNAPSHOT</spigot.version>
<bentobox.version>1.16.6-SNAPSHOT</bentobox.version>
<bentobox.version>1.20.0-SNAPSHOT</bentobox.version>
<level.version>2.9.0</level.version>
<limits.version>1.19.1-SNAPSHOT</limits.version>
<vault.version>1.7</vault.version>
Expand All @@ -62,7 +62,6 @@
<!-- Do not change unless you want different name for local builds. -->
<build.number>-LOCAL</build.number>
<!-- SonarCloud Analysis -->
<sonar.projectKey>BentoBoxWorld_Upgrades</sonar.projectKey>
<sonar.organization>bentobox-world</sonar.organization>
<sonar.host.url>https://sonarcloud.io</sonar.host.url>
</properties>
Expand Down

0 comments on commit 838507c

Please sign in to comment.