Skip to content

Update GitHub Actions non-major to v6.0.3 #1507

Update GitHub Actions non-major to v6.0.3

Update GitHub Actions non-major to v6.0.3 #1507

Workflow file for this run

name: Build
on:
pull_request:
branches:
- stable
- alpha
push:
branches:
- stable
- alpha
tags-ignore:
- "[0-9]+.[0-9]+.[0-9]+"
- "[0-9]+.[0-9]+.[0-9]+-*"
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3
with:
fetch-depth: 0
filter: tree:0
- name: Install Nix
uses: cachix/install-nix-action@8aa03977d8d733052d78f4e008a241fd1dbf36b3 # v31.10.6
- name: Setup dev environment
shell: &dev-shell 'nix develop -c bash -eo pipefail {0}'
run: 'true'
- name: Restore dependencies
shell: *dev-shell
run: dotnet restore
- name: Build
shell: *dev-shell
run: dotnet build -c Release --no-restore --warnaserror
- name: Test
shell: *dev-shell
run: dotnet test -c Release --no-build --verbosity normal
- name: Pack Packages
shell: *dev-shell
run: |
dotnet pack NetCord -c Release --no-build
dotnet pack NetCord.Services -c Release --no-build
dotnet pack Hosting/NetCord.Hosting -c Release --no-build
dotnet pack Hosting/NetCord.Hosting.Services -c Release --no-build
dotnet pack Hosting/NetCord.Hosting.AspNetCore -c Release --no-build
- name: Setup docs environment
shell: &docs-shell 'nix develop .#docs -c bash -eo pipefail {0}'
run: 'true'
- name: Build Documentation
shell: *docs-shell
working-directory: Documentation
run: |
npm install
npm run lint
npm run test
npm run build
- name: Upload Build Artifacts
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: Build Artifacts
path: |
NetCord/bin/Release
NetCord.Services/bin/Release
Hosting/NetCord.Hosting/bin/Release
Hosting/NetCord.Hosting.Services/bin/Release
Hosting/NetCord.Hosting.AspNetCore/bin/Release
- name: Upload Documentation Artifacts
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: Documentation Artifacts
path: Documentation/_site