Skip to content

Commit

Permalink
Bump codecov/codecov-action from 1 to 2 (#1038)
Browse files Browse the repository at this point in the history
* Bump codecov/codecov-action from 1 to 2

updated-dependencies:
- dependency-name: codecov/codecov-action
  dependency-type: direct:production
  update-type: version-update:semver-major

* Change cache keys (maven repo is platform independent)

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: Peter Trifanov <[email protected]>
Co-authored-by: Andrey Kuleshov <[email protected]>
  • Loading branch information
3 people authored Dec 14, 2021
1 parent 14d1272 commit 87ae5c0
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 18 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,15 @@ jobs:
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-build-${{ hashFiles('**/pom.xml') }}
key: maven-build-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-build-
maven-build-
- name: Maven Install
run: mvn -B clean install
- name: Code coverage report
uses: codecov/codecov-action@v1
uses: codecov/codecov-action@v2
with:
file: ./*/target/site/jacoco/jacoco.xml
files: '**/target/site/jacoco*/jacoco.xml,**/reports/jacoco/**/*.xml'
flags: unittests
fail_ci_if_error: true # optional (default = false)
- name: Upload diktat jar
Expand Down Expand Up @@ -130,9 +130,9 @@ jobs:
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-build-${{ hashFiles('**/pom.xml') }}
key: maven-build-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-build-
maven-build-
- name: Maven Install
if: ${{ runner.os == 'Linux' || runner.os == 'macOS' }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/detekt.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,9 @@ jobs:
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-detekt-${{ hashFiles('**/pom.xml') }}
key: maven-detekt-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-detekt-
maven-detekt-
# when running detekt with type resolution, we need to have all project modules compiled too
- name: running deteKT
run: mvn -B compile dependency:build-classpath@detekt detekt:check@detekt -DskipPluginMarker
4 changes: 2 additions & 2 deletions .github/workflows/diktat.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ jobs:
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-diktat-${{ hashFiles('**/pom.xml') }}
key: maven-diktat-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-diktat-
maven-diktat-
- name: Substitute diktat config with the one from the latest release
# fixme: can be done from the fetched repo without additional network request
run: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/diktat_snapshot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ jobs:
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-build-${{ hashFiles('**/pom.xml') }}
key: maven-build-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-build
maven-build
- name: Set version
# Set project version which will then be used to run diktat from local maven repo.
# Base version is stored in env variable for later usage.
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/metrics_for_master.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,15 @@ jobs:
# keys are the same as in build_and_test workflow to make cache available for PRs
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-build-${{ hashFiles('**/pom.xml') }}
key: maven-build-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-build-
maven-build-
- name: Run tests
# we need to run `install` goal here so that gradle will be able to resolve dependencies and run tests on diktat-gradle-plugin
run: mvn -B install -DskipPluginMarker
- name: Generate code coverage report
uses: codecov/codecov-action@v1
uses: codecov/codecov-action@v2
with:
file: ./*/target/site/jacoco/jacoco.xml
files: '**/target/site/jacoco*/jacoco.xml,**/reports/jacoco/**/*.xml'
flags: unittests
fail_ci_if_error: true # optional (default = false)
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ jobs:
uses: actions/cache@v2
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-master-${{ hashFiles('**/pom.xml') }}
key: maven-build-${{ hashFiles('**/pom.xml') }}
restore-keys: |
${{ runner.os }}-maven-master-
maven-build-
- name: Setup environment
env:
DIKTAT_GPG_PUB: ${{ secrets.DIKTAT_PGP_PUB }}
Expand Down

0 comments on commit 87ae5c0

Please sign in to comment.