Skip to content

chore(deps): update actions/cache digest to 5a3ec84 #1033

chore(deps): update actions/cache digest to 5a3ec84

chore(deps): update actions/cache digest to 5a3ec84 #1033

Workflow file for this run

name: ci
on:
push:
branches:
- main
tags:
- 'v*'
pull_request:
branches:
- main
env:
NUGET_PACKAGES: '${{ github.workspace }}/.nuget/packages'
jobs:
build-packages:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
with:
fetch-depth: 0
- name: NuGet Cache
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4
with:
path: |
${{ env.NUGET_PACKAGES }}
.nuke/temp
key: ${{ runner.os }}-nuget-${{ hashFiles('**/global.json', '**/*.csproj', '**/*.props') }}
restore-keys: |
${{ runner.os }}-nuget-
- name: Setup .NET
uses: actions/setup-dotnet@67a3573c9a986a3f9c594539f4ab511d57bb3ce9 # v4
with:
dotnet-version: 6.x # Required for dotnet-validate
global-json-file: ./global.json # Required, otherwise only the versions above get installed
- name: Restore .NET Tools
run: |
dotnet tool restore
- name: Build, Test and Pack
run: |
dotnet nuke
- name: Upload Coverage
uses: codecov/codecov-action@0565863a31f2c772f9f0395002a31e3f06189574 # v5
with:
version: v10.0.1 # Later versions break file search
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: true
directory: ${{ github.workspace }}/artifacts/coverage
files: "*.cobertura.xml"
- name: Upload Packages
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4
with:
name: packages
path: ${{ github.workspace }}/artifacts/packages
if-no-files-found: error
build-docs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
with:
fetch-depth: 0
- name: NPM Cache
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Setup Node.js
uses: actions/setup-node@cdca7365b2dadb8aad0a33bc7601856ffabcc48e # v4
with:
node-version: 'lts/iron'
- name: NuGet Cache
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4
with:
path: |
${{ env.NUGET_PACKAGES }}
.nuke/temp
key: ${{ runner.os }}-nuget-${{ hashFiles('**/global.json', '**/*.csproj', '**/*.props') }}
restore-keys: |
${{ runner.os }}-nuget-
- name: Setup .NET
uses: actions/setup-dotnet@67a3573c9a986a3f9c594539f4ab511d57bb3ce9 # v4
- name: Restore .NET Tools
run: |
dotnet tool restore
- name: Build Docs
run: |
dotnet nuke Docs
- name: Upload Docs
uses: actions/upload-pages-artifact@56afc609e74202658d3ffba0e8f6dda462b719fa # v3
with:
path: ${{ github.workspace }}/artifacts/docs
publish-packages:
runs-on: ubuntu-latest
needs: [build-packages]
# Only publish if build was triggered for a tag
if: startsWith(github.ref, 'refs/tags/v')
steps:
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
with:
fetch-depth: 0
- name: Download Packages
uses: actions/download-artifact@95815c38cf2ff2164869cbab79da8d1f422bc89e # v4
with:
name: packages
path: ${{ github.workspace }}/artifacts/packages
- name: Setup .NET
uses: actions/setup-dotnet@67a3573c9a986a3f9c594539f4ab511d57bb3ce9 # v4
- name: Restore .NET Tools
run: |
dotnet tool restore
- name: Publish NuGet packages
run: |
dotnet nuke Publish \
--nuget-api-key $NUGET_API_KEY
env:
NUGET_API_KEY: ${{ secrets.NUGET_API_KEY }}
publish-docs:
runs-on: ubuntu-latest
needs: [build-docs]
# Only publish if build was triggered for a tag
if: startsWith(github.ref, 'refs/tags/v')
permissions:
pages: write # to deploy to pages
id-token: write # to verify the deployment originates from an appropriate source
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
uses: actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e # v4
id: deployment