liuyuqi-cnb 1 day ago
parent
commit
8c140ef654
1 changed files with 12 additions and 1 deletions
  1. 12 1
      .github/workflows/build-windows.yml

+ 12 - 1
.github/workflows/build-windows.yml

@@ -14,7 +14,9 @@ on:
 jobs:
   build-windows:
     runs-on: windows-latest
-    
+
+    permissions:
+      actions: write
     steps:
     - name: Checkout code
       uses: actions/checkout@v4
@@ -65,3 +67,12 @@ jobs:
         prerelease: false
       env:
         GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
+
+
+    - name: Remove old artifacts
+      uses: c-hive/gha-remove-artifacts@v1
+      with:
+        age: '3 days' # '<number> <unit>', e.g. 5 days, 2 years, 90 seconds, parsed by Moment.js
+        # Optional inputs
+        # skip-tags: true
+        skip-recent: 1