Reduce B&T Artifact Retention Org-Wide (#72)

This commit is contained in:
UltraProdigy
2026-10-04 16:34:59 +02:00
committed by GitHub
parent 8d2e9d2fcf
commit be3d2919b6
+16 -13
View File
@@ -52,6 +52,9 @@ on:
default: false default: false
type: boolean type: boolean
env:
ARTIFACT_RETENTION_DAYS: ${{ github.event.repository.private && 5 || 30 }}
concurrency: concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true cancel-in-progress: true
@@ -157,14 +160,13 @@ jobs:
with: with:
name: ${{ github.repository_id }}-reports name: ${{ github.repository_id }}-reports
path: build/reports/ path: build/reports/
retention-days: 90 retention-days: ${{ env.ARTIFACT_RETENTION_DAYS }}
- name: Attempt to make a PR fixing spotless errors - name: Attempt to make a PR fixing spotless errors
if: >- if: >-
${{ !inputs.disable-spotless-pr && ${{ !inputs.disable-spotless-pr &&
failure() && steps.build_mod.conclusion == 'failure' && failure() && steps.build_mod.conclusion == 'failure' &&
github.event_name == 'pull_request' && github.event_name == 'pull_request' &&
!github.event.pull_request.draft &&
github.event.pull_request.head.repo.full_name == github.repository }} github.event.pull_request.head.repo.full_name == github.repository }}
run: | run: |
git reset --hard git reset --hard
@@ -288,11 +290,12 @@ jobs:
PR_NUMBER: ${{ github.event.number }} PR_NUMBER: ${{ github.event.number }}
- name: Attach compilation artifacts as ZIP - name: Attach compilation artifacts as ZIP
if: ${{ !github.event.repository.private }}
uses: actions/upload-artifact@v7 uses: actions/upload-artifact@v7
with: with:
name: ${{ github.repository_id }}-build-libs name: ${{ github.repository_id }}-build-libs
path: build/libs/ path: build/libs/
retention-days: 90 retention-days: ${{ env.ARTIFACT_RETENTION_DAYS }}
- name: Find individual compilation artifacts - name: Find individual compilation artifacts
id: find-artifacts id: find-artifacts
@@ -315,7 +318,7 @@ jobs:
uses: actions/upload-artifact@v7 uses: actions/upload-artifact@v7
with: with:
path: ${{ steps.find-artifacts.outputs.file_0 }} path: ${{ steps.find-artifacts.outputs.file_0 }}
retention-days: 90 retention-days: ${{ env.ARTIFACT_RETENTION_DAYS }}
archive: false archive: false
- name: Upload individual compilation artifact 2 - name: Upload individual compilation artifact 2
@@ -323,7 +326,7 @@ jobs:
uses: actions/upload-artifact@v7 uses: actions/upload-artifact@v7
with: with:
path: ${{ steps.find-artifacts.outputs.file_1 }} path: ${{ steps.find-artifacts.outputs.file_1 }}
retention-days: 90 retention-days: ${{ env.ARTIFACT_RETENTION_DAYS }}
archive: false archive: false
- name: Upload individual compilation artifact 3 - name: Upload individual compilation artifact 3
@@ -331,7 +334,7 @@ jobs:
uses: actions/upload-artifact@v7 uses: actions/upload-artifact@v7
with: with:
path: ${{ steps.find-artifacts.outputs.file_2 }} path: ${{ steps.find-artifacts.outputs.file_2 }}
retention-days: 90 retention-days: ${{ env.ARTIFACT_RETENTION_DAYS }}
archive: false archive: false
- name: Upload individual compilation artifact 4 - name: Upload individual compilation artifact 4
@@ -339,7 +342,7 @@ jobs:
uses: actions/upload-artifact@v7 uses: actions/upload-artifact@v7
with: with:
path: ${{ steps.find-artifacts.outputs.file_3 }} path: ${{ steps.find-artifacts.outputs.file_3 }}
retention-days: 90 retention-days: ${{ env.ARTIFACT_RETENTION_DAYS }}
archive: false archive: false
- name: Upload individual compilation artifact 5 - name: Upload individual compilation artifact 5
@@ -347,7 +350,7 @@ jobs:
uses: actions/upload-artifact@v7 uses: actions/upload-artifact@v7
with: with:
path: ${{ steps.find-artifacts.outputs.file_4 }} path: ${{ steps.find-artifacts.outputs.file_4 }}
retention-days: 90 retention-days: ${{ env.ARTIFACT_RETENTION_DAYS }}
archive: false archive: false
- name: Upload individual compilation artifact 6 - name: Upload individual compilation artifact 6
@@ -355,7 +358,7 @@ jobs:
uses: actions/upload-artifact@v7 uses: actions/upload-artifact@v7
with: with:
path: ${{ steps.find-artifacts.outputs.file_5 }} path: ${{ steps.find-artifacts.outputs.file_5 }}
retention-days: 90 retention-days: ${{ env.ARTIFACT_RETENTION_DAYS }}
archive: false archive: false
- name: Upload individual compilation artifact 7 - name: Upload individual compilation artifact 7
@@ -363,7 +366,7 @@ jobs:
uses: actions/upload-artifact@v7 uses: actions/upload-artifact@v7
with: with:
path: ${{ steps.find-artifacts.outputs.file_6 }} path: ${{ steps.find-artifacts.outputs.file_6 }}
retention-days: 90 retention-days: ${{ env.ARTIFACT_RETENTION_DAYS }}
archive: false archive: false
- name: Upload individual compilation artifact 8 - name: Upload individual compilation artifact 8
@@ -371,7 +374,7 @@ jobs:
uses: actions/upload-artifact@v7 uses: actions/upload-artifact@v7
with: with:
path: ${{ steps.find-artifacts.outputs.file_7 }} path: ${{ steps.find-artifacts.outputs.file_7 }}
retention-days: 90 retention-days: ${{ env.ARTIFACT_RETENTION_DAYS }}
archive: false archive: false
- name: Upload individual compilation artifact 9 - name: Upload individual compilation artifact 9
@@ -379,7 +382,7 @@ jobs:
uses: actions/upload-artifact@v7 uses: actions/upload-artifact@v7
with: with:
path: ${{ steps.find-artifacts.outputs.file_8 }} path: ${{ steps.find-artifacts.outputs.file_8 }}
retention-days: 90 retention-days: ${{ env.ARTIFACT_RETENTION_DAYS }}
archive: false archive: false
- name: Upload individual compilation artifact 10 - name: Upload individual compilation artifact 10
@@ -387,5 +390,5 @@ jobs:
uses: actions/upload-artifact@v7 uses: actions/upload-artifact@v7
with: with:
path: ${{ steps.find-artifacts.outputs.file_9 }} path: ${{ steps.find-artifacts.outputs.file_9 }}
retention-days: 90 retention-days: ${{ env.ARTIFACT_RETENTION_DAYS }}
archive: false archive: false