From c81fb89ffdb14c5208c60c2907f1347f797b0356 Mon Sep 17 00:00:00 2001 From: hustcer Date: Fri, 1 Nov 2024 15:39:51 +0800 Subject: [PATCH] Update nightly build workflow improve cleanup of old nightly builds --- .github/workflows/nightly-build.yml | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/.github/workflows/nightly-build.yml b/.github/workflows/nightly-build.yml index 111c6df03..6101fcbad 100644 --- a/.github/workflows/nightly-build.yml +++ b/.github/workflows/nightly-build.yml @@ -4,6 +4,7 @@ # 2. https://github.com/JasonEtco/create-an-issue # 3. https://docs.github.com/en/actions/learn-github-actions/variables # 4. https://github.com/actions/github-script +# 5. https://docs.github.com/en/actions/writing-workflows/workflow-syntax-for-github-actions#jobsjob_idneeds # name: Nightly Build @@ -40,7 +41,7 @@ jobs: uses: hustcer/setup-nu@v3 if: github.repository == 'nushell/nightly' with: - version: 0.98.0 + version: 0.99.1 # Synchronize the main branch of nightly repo with the main branch of Nushell official repo - name: Prepare for Nightly Release @@ -142,7 +143,7 @@ jobs: - name: Setup Nushell uses: hustcer/setup-nu@v3 with: - version: 0.98.0 + version: 0.99.1 - name: Release Nu Binary id: nu @@ -213,12 +214,9 @@ jobs: name: Cleanup # Should only run in nushell/nightly repo if: github.repository == 'nushell/nightly' + needs: [release, sha256sum] runs-on: ubuntu-latest steps: - # Sleep for 30 minutes, waiting for the release to be published - - name: Waiting for Release - run: sleep 1800 - - uses: actions/checkout@v4 with: ref: main @@ -226,7 +224,7 @@ jobs: - name: Setup Nushell uses: hustcer/setup-nu@v3 with: - version: 0.98.0 + version: 0.99.1 # Keep the last a few releases - name: Delete Older Releases