Delicious On Terra #392
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: build | |
on: [push, pull_request, workflow_dispatch] | |
env: | |
LPRUN_URL: https://www.linqpad.net/GetFile.aspx?preview+LINQPad8-Beta.zip | |
LPRUN: LPRun8-x64.exe --% -fx=9.0 | |
COMPILE_ONLY: -compileonly | |
ARTIFACT_NAME: LatestCommit | |
RETENTION_DAYS: 30 | |
jobs: | |
build: | |
runs-on: windows-latest | |
steps: | |
# Set up | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v4.3.0 | |
with: | |
dotnet-version: | | |
9.0.x | |
# Set up LPRun | |
- name: Set up LPRun | |
uses: Alex079/setup-custom-tool@v2.0.0 | |
with: | |
archiveUrl: ${{env.LPRUN_URL}} | |
# Check out | |
- name: Check out | |
uses: actions/checkout@v4.2.2 | |
# LPRun scripts | |
- name: LPRun EventStatus.linq | |
if: ${{success() || failure()}} | |
run: ${{env.LPRUN}} EventStatus.linq | |
- name: LPRun EventStockScraper.linq | |
if: ${{success() || failure()}} | |
run: ${{env.LPRUN}} ${{env.COMPILE_ONLY}} EventStockScraper.linq | |
- name: LPRun Hourglass.linq | |
if: ${{success() || failure()}} | |
run: ${{env.LPRUN}} ${{env.COMPILE_ONLY}} Hourglass.linq | |
- name: LPRun OperationStrategies.linq | |
if: ${{success() || failure()}} | |
run: ${{env.LPRUN}} OperationStrategies.linq | |
- name: LPRun OperatorModules.linq | |
if: ${{success() || failure()}} | |
run: ${{env.LPRUN}} OperatorModules.linq | |
- name: LPRun OperatorModulesScraper.linq | |
if: ${{success() || failure()}} | |
run: ${{env.LPRUN}} ${{env.COMPILE_ONLY}} OperatorModulesScraper.linq | |
- name: LPRun OriginitePrimePacks.linq | |
if: ${{success() || failure()}} | |
run: ${{env.LPRUN}} OriginitePrimePacks.linq | |
- name: Archive latest commit | |
if: ${{success() || failure()}} | |
run: | | |
$ErrorActionPreference = 'Stop' | |
$Verbose = $VerbosePreference -ne 'SilentlyContinue' | |
# Get latest commit message. | |
$message = "Arknights-$((git show-branch --no-name HEAD).Trim() -replace ' event$','' -replace ' ','_')" | |
# Export latest commit to the commit message dir. | |
git checkout-index -a -f --prefix=./$message/ | |
# Archive latest commit message dir. | |
7z a -tzip -mx=9 $message $message/* '-xr!.github' | |
- name: Upload latest commit archive | |
uses: actions/upload-artifact@v4.6.1 | |
with: | |
name: ${{env.ARTIFACT_NAME}} | |
path: | | |
*.zip | |
compression-level: 0 | |
retention-days: ${{env.RETENTION_DAYS}} |