v8.13.0 #14
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Exiled CD | |
on: | |
release: | |
types: [published] | |
workflow_dispatch: | |
defaults: | |
run: | |
working-directory: ./EXILED | |
env: | |
EXILED_REFERENCES_URL: https://ExMod-Team.github.io/SL-References/Master.zip | |
EXILED_REFERENCES_PATH: ${{ github.workspace }}/EXILED/References | |
jobs: | |
push: | |
runs-on: windows-latest | |
steps: | |
- name: Setup .NET Core SDK | |
uses: actions/[email protected] | |
- name: Setup Nuget | |
uses: NuGet/setup-nuget@v2 | |
- uses: actions/[email protected] | |
- name: Get references | |
shell: pwsh | |
run: | | |
Invoke-WebRequest -Uri ${{ env.EXILED_REFERENCES_URL }} -OutFile ${{ github.workspace }}/EXILED/References.zip | |
Expand-Archive -Path References.zip -DestinationPath ${{ env.EXILED_REFERENCES_PATH }} | |
- name: Build NuGet | |
env: | |
EXILED_REFERENCES: ${{ env.EXILED_REFERENCES_PATH }} | |
shell: pwsh | |
run: | | |
./build.ps1 -BuildNuGet | |
$File = (Get-ChildItem -Path . -Include 'ExMod.Exiled.*.nupkg' -Recurse).Name | |
Out-File -FilePath ${{ github.env }} -InputObject "PackageFile=$File" -Encoding utf-8 -Append | |
- name: Push NuGet | |
shell: pwsh | |
run: nuget push ${{ env.PackageFile }} -ApiKey ${{ secrets.NUGET_API_KEY }} -Source https://api.nuget.org/v3/index.json -SkipDuplicate | |
- name: Push generated package to GitHub registry | |
run: dotnet nuget push ${{ env.PackageFile }} -k ${{ secrets.GITHUB_TOKEN }} -s https://nuget.pkg.github.com/ExMod-Team/index.json --skip-duplicate |