-
-
Notifications
You must be signed in to change notification settings - Fork 62
chore: bump actions in ci #2665
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
dfcc4a3
a151043
60f16df
89c9a5b
964c006
977760a
ee9ab8d
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,33 @@ | ||
| name: 'Wait for and download artifact' | ||
| description: 'Polls the run''s artifacts API until the named artifact appears, then downloads it.' | ||
| inputs: | ||
| name: | ||
| description: 'Artifact name' | ||
| required: true | ||
| path: | ||
| description: 'Destination path for the artifact contents' | ||
| required: false | ||
|
|
||
| runs: | ||
| using: composite | ||
| steps: | ||
| - name: Wait for ${{ inputs.name }} | ||
| env: | ||
| GH_TOKEN: ${{ github.token }} | ||
| NAME: ${{ inputs.name }} | ||
| shell: pwsh | ||
| run: | | ||
| for ($i = 0; $i -lt 120; $i++) { | ||
| $count = gh api "/repos/$env:GITHUB_REPOSITORY/actions/runs/$env:GITHUB_RUN_ID/artifacts?name=$env:NAME" --jq .total_count | ||
| if ([int]$count -gt 0) { | ||
| exit 0 | ||
| } | ||
| Start-Sleep -Seconds 30 | ||
| } | ||
| Write-Error "Timed out after 60 minutes waiting for artifact: $env:NAME" | ||
| exit 1 | ||
|
|
||
| - uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1 | ||
| with: | ||
| name: ${{ inputs.name }} | ||
| path: ${{ inputs.path }} |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -26,7 +26,7 @@ jobs: | |
| contents: read | ||
| steps: | ||
| - name: Checkout | ||
| uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3 | ||
| uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Missing
|
||
|
|
||
| - name: Free Disk Space (Ubuntu) | ||
| uses: jlumbroso/free-disk-space@f68fdb76e2ea636224182cfb7377ff9a1708f9b8 # v1.3.0 | ||
|
|
@@ -48,15 +48,15 @@ jobs: | |
| UNITY_SCRIPT_ARG: unity${{ env.UNITY_VERSION }} | ||
|
|
||
| - name: Cache Unity Library | ||
| uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0 | ||
| uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5 | ||
| with: | ||
| path: samples/unity-of-bugs/Library | ||
| key: Library-unity-of-bugs-${{ steps.env.outputs.unityVersion }}-v1 | ||
| restore-keys: | | ||
| Library-unity-of-bugs-${{ steps.env.outputs.unityVersion }}- | ||
|
|
||
| - name: Docker Login | ||
| uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # pinned v3 | ||
| uses: docker/login-action@4907a6ddec9925e35a0a9e82d7399ccc52663121 # v4.1.0 | ||
| with: | ||
| registry: ghcr.io | ||
| username: ${{ env.GITHUB_ACTOR }} | ||
|
|
@@ -70,7 +70,7 @@ jobs: | |
|
|
||
| - name: Install .NET SDK | ||
| if: runner.os != 'Windows' | ||
| uses: actions/setup-dotnet@d4c94342e560b34958eacfc5d055d21461ed1c5d # v5 | ||
| uses: actions/setup-dotnet@c2fa09f4bde5ebb9d1777cf28262a3eb3db3ced7 # v5.2.0 | ||
| with: | ||
| global-json-file: global.json | ||
|
|
||
|
|
@@ -81,32 +81,28 @@ jobs: | |
| run: ./scripts/download-sentry-cli.ps1 | ||
|
|
||
| - name: Download Android SDK | ||
| uses: vaind/download-artifact@e7141b6a94ef28aa3d828b52830cfa1f406a1848 # v4-with-wait-timeout | ||
| uses: ./.github/actions/wait-for-artifact | ||
| with: | ||
| name: Android-sdk | ||
| path: package-dev/Plugins/Android | ||
| wait-timeout: 3600 | ||
|
|
||
| - name: Download Cocoa SDK | ||
| uses: vaind/download-artifact@e7141b6a94ef28aa3d828b52830cfa1f406a1848 # v4-with-wait-timeout | ||
| uses: ./.github/actions/wait-for-artifact | ||
| with: | ||
| name: Cocoa-sdk | ||
| path: package-dev/Plugins | ||
| wait-timeout: 3600 | ||
|
|
||
| - name: Download Linux SDK | ||
| uses: vaind/download-artifact@e7141b6a94ef28aa3d828b52830cfa1f406a1848 # v4-with-wait-timeout | ||
| uses: ./.github/actions/wait-for-artifact | ||
| with: | ||
| name: Linux-sdk | ||
| path: package-dev/Plugins/Linux | ||
| wait-timeout: 3600 | ||
|
|
||
| - name: Download Windows SDK | ||
| uses: vaind/download-artifact@e7141b6a94ef28aa3d828b52830cfa1f406a1848 # v4-with-wait-timeout | ||
| uses: ./.github/actions/wait-for-artifact | ||
| with: | ||
| name: Windows-sdk | ||
| path: package-dev/Plugins/Windows | ||
| wait-timeout: 3600 | ||
|
|
||
| - name: Build Sentry.Unity Solution | ||
| run: docker exec unity dotnet build -c Release -v:d | ||
|
|
@@ -126,7 +122,7 @@ jobs: | |
| ./scripts/pack.ps1 | ||
|
|
||
| - name: Upload release artifacts | ||
| uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 | ||
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 | ||
| with: | ||
| name: package-release | ||
| if-no-files-found: error | ||
|
|
@@ -140,7 +136,7 @@ jobs: | |
| run: docker exec unity dotnet msbuild /t:UnityEditModeTest /p:Configuration=Release /p:OutDir=other test/Sentry.Unity.Editor.Tests | ||
|
|
||
| - name: Publish Test Results | ||
| uses: dorny/test-reporter@dc3a92680fcc15842eef52e8c4606ea7ce6bd3f3 # v2.1.1 | ||
| uses: dorny/test-reporter@a6ddd83ac95ff4586f5d3aceeb314d9a1841db95 # v3.0.0 | ||
| if: ${{ !cancelled() }} | ||
| with: | ||
| name: Unity Test Results - ${{ env.UNITY_VERSION }} | ||
|
|
@@ -149,13 +145,13 @@ jobs: | |
| fail-on-error: false | ||
|
|
||
| - name: Upload test artifacts (playmode) | ||
| uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 | ||
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 | ||
| with: | ||
| name: Test results (playmode) - ${{ env.UNITY_VERSION }} | ||
| path: artifacts/test/playmode | ||
|
|
||
| - name: Upload test artifacts (editmode) | ||
| uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 | ||
| uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 | ||
| with: | ||
| name: Test results (editmode) - ${{ env.UNITY_VERSION }} | ||
| path: artifacts/test/editmode | ||


Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We previously relied on this fork https://github.com/vaind/download-artifact (that is in dire need of getting synced), or, like here, we wrap
action/download-artifactin 10 lines of bash and call it a day.