diff --git a/.github/workflows/basic_checks.yaml b/.github/workflows/basic_checks.yaml index bd99120..9bc5d72 100644 --- a/.github/workflows/basic_checks.yaml +++ b/.github/workflows/basic_checks.yaml @@ -17,7 +17,7 @@ jobs: steps: - name: Checkout Repository - uses: actions/checkout@v4 + uses: actions/checkout@v6 - name: Query dependencies and update old packages run: | @@ -28,7 +28,7 @@ jobs: - name: Cache R packages if: runner.os != 'Windows' - uses: actions/cache@v4 + uses: actions/cache@v5 with: path: /usr/local/lib/R/site-library key: ${{ env.cache-version }}-${{ runner.os }}-r-${{ hashFiles('.github/depends.Rds') }} @@ -52,12 +52,35 @@ jobs: PATH=$PATH:$HOME/bin/ Rscript -e 'pkgdown::build_site(".")' - name: Upload pkgdown artifact - uses: actions/upload-pages-artifact@v3 + if: github.event_name == 'push' + uses: actions/upload-artifact@v4 with: + name: pkgdown-site path: docs + deploy: + needs: r-build-and-check + if: github.event_name == 'push' && success() + runs-on: ubuntu-latest + permissions: + contents: write + steps: + - name: Checkout Repository + uses: actions/checkout@v6 + + - name: Download pkgdown artifact + uses: actions/download-artifact@v4 + with: + name: pkgdown-site + path: _site + + - name: Deploy to GitHub Pages + uses: JamesIves/github-pages-deploy-action@v4 + with: + branch: gh-pages + folder: _site + docker-build-and-push: - #needs: r-build-and-check runs-on: ubuntu-latest permissions: contents: read @@ -68,7 +91,7 @@ jobs: steps: - name: Checkout Repository - uses: actions/checkout@v4 + uses: actions/checkout@v6 - name: Set Environment Variables run: | @@ -87,16 +110,16 @@ jobs: # https://github.com/sigstore/cosign-installer - name: Install cosign if: github.event_name != 'pull_request' - uses: sigstore/cosign-installer@v3 + uses: sigstore/cosign-installer@v4.1.1 - name: Setup Docker buildx - uses: docker/setup-buildx-action@v3 + uses: docker/setup-buildx-action@v4 # Login against a Docker registry except on PR # https://github.com/docker/login-action - name: Log into registry ${{ env.REGISTRY }} if: github.event_name != 'pull_request' - uses: docker/login-action@v3 + uses: docker/login-action@v4 with: registry: ${{ env.REGISTRY }} username: ${{ github.actor }} @@ -106,7 +129,7 @@ jobs: # https://github.com/docker/metadata-action - name: Extract Docker metadata id: meta - uses: docker/metadata-action@v5 + uses: docker/metadata-action@v6 with: images: ${{ env.IMAGE }} @@ -114,24 +137,10 @@ jobs: # https://github.com/docker/build-push-action - name: Build and push Docker image id: build-and-push - uses: docker/build-push-action@v6 + uses: docker/build-push-action@v7 with: context: . push: ${{ github.event_name != 'pull_request' }} tags: | ${{ env.IMAGE }}:latest - ${{ env.IMAGE }}:${{ env.GIT_SHA }} - - deploy: - needs: r-build-and-check - permissions: - pages: write - id-token: write - runs-on: ubuntu-24.04 - environment: - name: github-pages - url: ${{ steps.deployment.outputs.page_url }} - steps: - - name: Deploy to GitHub Pages - id: deployment - uses: actions/deploy-pages@v4 \ No newline at end of file + ${{ env.IMAGE }}:${{ env.GIT_SHA }} \ No newline at end of file