Skip to content

Merge branch 'main' of github.com:CSGALS/CSSUniversalMenuAPI #6

Merge branch 'main' of github.com:CSGALS/CSSUniversalMenuAPI

Merge branch 'main' of github.com:CSGALS/CSSUniversalMenuAPI #6

# WARNING: This file is automatically generated by ../regenerate-actions.sh
name: CD
on:
push:
branches:
- main
- support/*
paths-ignore:
- docs/**
- README.md
- .editorconfig
- .gitattributes
- .gitignore
- .github/ISSUE_TEMPLATE/**
- .github/pull_request_template.md
defaults:
run:
shell: bash
jobs:
build:
name: Continuous delivery
runs-on: ubuntu-24.04
permissions:
packages: write
steps:
- uses: actions/checkout@v4
with:
fetch-depth: '0'
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: |
8.x
9.x
- name: Setup NuGet
run: |
dotnet nuget update source csgals --store-password-in-clear-text --username CSGALS --password ${{ secrets.GITHUB_TOKEN }}
dotnet nuget enable source csgals
- name: Restore
run: dotnet restore
- name: Build
run: dotnet build --configuration Release --no-restore
- name: Test
run: dotnet test --configuration Debug --logger GitHubActions -p:CollectCoverage=true
-p:CoverletOutputFormat=cobertura
- name: Pack
run: dotnet pack -p:PackageOutputPath="$(pwd)/artifacts" --configuration Release
--no-restore
- name: Build CSS Package
run: |
src="./src/CSSUniversalMenuAPI/bin/Release/net8.0"
dst="./artifacts/CSSUniversalMenuAPI"
dst_shared="$dst/addons/counterstrikesharp/shared/CSSUniversalMenuAPI"
mkdir -p "$dst_shared"
cp "$src/CSSUniversalMenuAPI.dll" "$dst_shared/"
cp "$src/CSSUniversalMenuAPI.deps.json" "$dst_shared/"
pushd "$dst"
7z a ../CSSUniversalMenuAPI.zip ./
popd
rm -rf "$dst"
- name: Upload Artifacts
uses: actions/upload-artifact@v4
if: success() || failure()
with:
name: artifacts
if-no-files-found: error
path: |
artifacts/*
- name: Publish NuGet GitHub
run: dotnet nuget push 'artifacts/*.nupkg' -k ${{ secrets.GITHUB_TOKEN }} -s
csgals --skip-duplicate --no-symbols