diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 00000000..c2b928dc --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,44 @@ +version: 2 +updates: + - package-ecosystem: "maven" + directory: "/" + schedule: + interval: "weekly" + day: "monday" + time: "06:00" + timezone: "UTC" + groups: + java-test-dependencies: + patterns: + - "org.junit.jupiter:*" + - "org.mockito:*" + - "org.hamcrest:*" + - "com.google.jimfs:jimfs" + maven-build-plugins: + patterns: + - "org.apache.maven.plugins:*" + - "org.jacoco:jacoco-maven-plugin" + - "org.owasp:dependency-check-maven" + java-production-dependencies: + patterns: + - "*" + exclude-patterns: + - "org.apache.maven.plugins:*" + - "org.jacoco:jacoco-maven-plugin" + - "org.owasp:dependency-check-maven" + - "org.junit.jupiter:*" + - "org.mockito:*" + - "org.hamcrest:*" + - "com.google.jimfs:jimfs" + + + - package-ecosystem: "github-actions" + directory: "/" # even for `.github/workflows` + schedule: + interval: "monthly" + groups: + github-actions: + patterns: + - "*" + labels: + - "ci" diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 8d9f79be..fa25f713 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -5,11 +5,11 @@ jobs: build: name: Build and Test runs-on: ubuntu-latest - if: "!contains(github.event.head_commit.message, '[ci skip]') && !contains(github.event.head_commit.message, '[skip ci]')" steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: fetch-depth: 0 + show-progress: false - uses: actions/setup-java@v3 with: java-version: 17 @@ -29,7 +29,7 @@ jobs: mvn -B verify jacoco:report org.sonarsource.scanner.maven:sonar-maven-plugin:sonar - -Pcoverage,dependency-check + -Pcoverage -Dsonar.projectKey=cryptomator_cryptofs -Dsonar.organization=cryptomator -Dsonar.host.url=https://sonarcloud.io @@ -40,12 +40,10 @@ jobs: with: name: artifacts path: target/*.jar - - name: Create Release - uses: actions/create-release@v1 #NOTE: action is archived and unmaintained + - name: Create release if: startsWith(github.ref, 'refs/tags/') - env: - GITHUB_TOKEN: ${{ secrets.CRYPTOBOT_RELEASE_TOKEN }} # release as "cryptobot" + uses: softprops/action-gh-release@v1 with: - tag_name: ${{ github.ref }} - release_name: Release ${{ github.ref }} + token: ${{ secrets.CRYPTOBOT_RELEASE_TOKEN }} + generate_release_notes: true prerelease: true \ No newline at end of file diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index c9c1a68c..b90c55f8 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -13,11 +13,13 @@ jobs: analyse: name: Analyse runs-on: ubuntu-latest - if: "!contains(github.event.head_commit.message, '[ci skip]') && !contains(github.event.head_commit.message, '[skip ci]')" + # dependeabot has on push events only read-only access, but codeql requires write access + if: ${{ !(github.actor == 'dependabot[bot]' && contains(fromJSON('["push"]'), github.event_name)) }} steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: fetch-depth: 2 + show-progress: false - uses: actions/setup-java@v3 with: java-version: 17 @@ -27,7 +29,7 @@ jobs: uses: github/codeql-action/init@v2 with: languages: java - - name: Build and Test + - name: Build run: mvn -B install -DskipTests - name: Perform CodeQL Analysis uses: github/codeql-action/analyze@v2 \ No newline at end of file diff --git a/.github/workflows/publish-central.yml b/.github/workflows/publish-central.yml index 35deee11..3260070c 100644 --- a/.github/workflows/publish-central.yml +++ b/.github/workflows/publish-central.yml @@ -10,9 +10,10 @@ jobs: publish: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: ref: "refs/tags/${{ github.event.inputs.tag }}" + show-progress: false - uses: actions/setup-java@v3 with: java-version: 17 diff --git a/.github/workflows/publish-github.yml b/.github/workflows/publish-github.yml index 6a9b3e33..37166beb 100644 --- a/.github/workflows/publish-github.yml +++ b/.github/workflows/publish-github.yml @@ -7,7 +7,9 @@ jobs: runs-on: ubuntu-latest if: startsWith(github.ref, 'refs/tags/') # only allow publishing tagged versions steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 + with: + show-progress: false - uses: actions/setup-java@v3 with: java-version: 17 diff --git a/.idea/misc.xml b/.idea/misc.xml index 58ff93ce..67e1e611 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -1,5 +1,6 @@ +