From b5c266d55afd1e2b8a52483114d12ca2b12cf5dc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20M=C3=A4nnchen?= Date: Fri, 15 Dec 2023 11:12:00 +0100 Subject: [PATCH] Upgrade @actions/artifact actions (#311) --- .github/SECURITY.md | 2 +- .github/workflows/part_docs.yml | 4 +-- .github/workflows/part_publish.yml | 4 +-- .github/workflows/part_test.yml | 54 ++++++++++++------------------ 4 files changed, 26 insertions(+), 38 deletions(-) diff --git a/.github/SECURITY.md b/.github/SECURITY.md index 9adc2c1..db023cf 100644 --- a/.github/SECURITY.md +++ b/.github/SECURITY.md @@ -19,4 +19,4 @@ report. If the issue is confirmed as a vulnerability, we will open a Security Advisory. This project follows a 90 day disclosure timeline. If you have questions about reporting security issues, email the vulnerability -management team: [`security@erlef.org`](mailto:security@erlef.org) \ No newline at end of file +management team: [`security@erlef.org`](mailto:security@erlef.org) diff --git a/.github/workflows/part_docs.yml b/.github/workflows/part_docs.yml index dcd7321..175c175 100644 --- a/.github/workflows/part_docs.yml +++ b/.github/workflows/part_docs.yml @@ -34,7 +34,7 @@ jobs: docs-bdepsuild-{{ runner.os }}-${{ steps.setupBEAM.outputs.otp-version }}-${{ steps.setupBEAM.outputs.elixir-version }}- - run: mix deps.get - run: mix docs - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: name: docs path: doc @@ -53,7 +53,7 @@ jobs: steps: - uses: actions/checkout@v4 - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v4 with: name: docs path: docs diff --git a/.github/workflows/part_publish.yml b/.github/workflows/part_publish.yml index cba1bd6..c1ab915 100644 --- a/.github/workflows/part_publish.yml +++ b/.github/workflows/part_publish.yml @@ -68,7 +68,7 @@ jobs: mix_hex_build-deps-${{ runner.os }}-${{ steps.setupBEAM.outputs.otp-version }}- - run: mix deps.get - run: mix hex.build --output package.tar - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: name: package path: package.tar @@ -87,7 +87,7 @@ jobs: steps: - uses: actions/checkout@v4 - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v4 with: name: package path: . diff --git a/.github/workflows/part_test.yml b/.github/workflows/part_test.yml index d658021..3e3ccf7 100644 --- a/.github/workflows/part_test.yml +++ b/.github/workflows/part_test.yml @@ -115,9 +115,9 @@ jobs: eunit-${{ runner.os }}-${{ steps.setupBEAM.outputs.otp-version }}- - run: rebar3 eunit --cover --cover_export_name "eunit-${{ steps.setupBEAM.outputs.otp-version }}" continue-on-error: ${{ matrix.unstable }} - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: - name: eunit-coverage + name: eunit-coverage-${{ matrix.otp }} path: "_build/test/cover/eunit-${{ steps.setupBEAM.outputs.otp-version }}.coverdata" conformance: @@ -154,9 +154,9 @@ jobs: ct-${{ runner.os }}-${{ steps.setupBEAM.outputs.otp-version }}- - run: rebar3 ct --cover --cover_export_name "ct-${{ steps.setupBEAM.outputs.otp-version }}" continue-on-error: ${{ matrix.unstable }} - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: - name: ct-coverage + name: ct-coverage-${{ matrix.otp }} path: _build/test/cover/ct-${{ steps.setupBEAM.outputs.otp-version }}.coverdata mix_test: @@ -203,9 +203,9 @@ jobs: - run: mix deps.get - run: mix test --cover --export-coverage "mix_test-${{ steps.setupBEAM.outputs.elixir-version }}" continue-on-error: ${{ matrix.unstable }} - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: - name: mix_test-coverage + name: mix_test-coverage-${{ matrix.elixir }} path: cover/mix_test-${{ steps.setupBEAM.outputs.elixir-version }}.coverdata coverage: @@ -228,18 +228,14 @@ jobs: key: mix_test_coverage-${{ runner.os }}-${{ steps.setupBEAM.outputs.otp-version }}-${{ steps.setupBEAM.outputs.elixir-version }}-${{ hashFiles('mix.exs') }} restore-keys: | mix_test_coverage-${{ runner.os }}-${{ steps.setupBEAM.outputs.otp-version }}-${{ steps.setupBEAM.outputs.elixir-version }}- - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v4 with: - name: ct-coverage - path: cover - - uses: actions/download-artifact@v3 - with: - name: eunit-coverage - path: cover - - uses: actions/download-artifact@v3 - with: - name: mix_test-coverage - path: cover + path: artifacts + - name: Unpack Artifacts + run: | + mkdir cover + mv artifacts/*/*.coverdata cover + rm -rf artifacts - uses: actions/cache@v3 with: path: deps @@ -248,7 +244,7 @@ jobs: mix_test_coverage-deps-${{ runner.os }}-${{ steps.setupBEAM.outputs.otp-version }}-${{ steps.setupBEAM.outputs.elixir-version }}- - run: mix deps.get - run: mix test.coverage - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: name: coverage-report path: cover @@ -273,22 +269,14 @@ jobs: key: cover-${{ runner.os }}-${{ steps.setupBEAM.outputs.otp-version }}-${{ hashFiles('rebar.config') }} restore-keys: | cover-${{ runner.os }}-${{ steps.setupBEAM.outputs.otp-version }}- - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v4 with: - name: ct-coverage - path: _build/test/cover/ - - uses: actions/download-artifact@v3 - with: - name: eunit-coverage - path: _build/test/cover/ - - uses: actions/download-artifact@v3 - with: - name: mix_test-coverage - path: _build/test/cover/ - - uses: actions/upload-artifact@v3 - with: - name: coverage-report - path: _build/test/cover/ + path: artifacts + - name: Unpack Artifacts + run: | + mkdir -p _build/test/cover/ + mv artifacts/*/*.coverdata _build/test/cover/ + rm -rf artifacts - run: rebar3 as test compile - run: rebar3 as test coveralls send env: