Skip to content

Update

Update #45

Workflow file for this run

name: Build-debug
on:
push:
branches: [ "develop" ]
jobs:
build:
runs-on: ubuntu-latest
if: ${{ github.repository_owner == 'TheIdealShipAU' }}
steps:
- uses: actions/cache@v2
with:
path: |
~/.nuget/packages
~/.cache/bepinex
key: ${{ runner.os }}-nuget-${{ hashFiles('**/packages.lock.json') }}
restore-keys: |
${{ runner.os }}-nuget-
- uses: actions/checkout@v2
with:
submodules: true
- name: Collect build info
id: info
uses: actions/github-script@v6
with:
script: |
let shortHash = "";
await exec.exec("git", ["rev-parse", "--short", "HEAD"],
{
listeners:
{
stdout: d => shortHash += d.toString().trim(),
}
});
core.setOutput("sha_short", shortHash);
- name: Setup .NET
uses: actions/setup-dotnet@v1
with:
dotnet-version: 6.x
- name: build
run: dotnet build TheIdealShip/TheIdealShip.csproj
- name: zip
run: zip TheIdealShip_${{ steps.info.outputs.sha_short }}.dll.zip TheIdealShip/bin/Debug/net6.0/TheIdealShip.dll
- name: upload to alist
run: "curl -X 'PUT' 'pan.pafyx.top/api/fs/form' -H 'File-Path: /TIS_Debug/TheIdealShip_${{ steps.info.outputs.sha_short }}.dll.zip' -F file='@TheIdealShip_${{ steps.info.outputs.sha_short }}.dll.zip' -H 'Authorization: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VybmFtZSI6IlRJUyIsImV4cCI6MTY4Njg3NjM3MCwibmJmIjoxNjg2NzAzNTcwLCJpYXQiOjE2ODY3MDM1NzB9.m_u9uKnoFDTo9f0c6Ida3iostaJs2Vc2g0myHoqiY_k'"
- name: upload TheIdealShip.dll
uses: actions/upload-artifact@v3
with:
name: TheIdealShip_${{ steps.info.outputs.sha_short }}.dll
path: TheIdealShip/bin/Debug/net6.0/TheIdealShip.dll