Skip to content

Updating metadata read/write to be more ubiquitous #8

Updating metadata read/write to be more ubiquitous

Updating metadata read/write to be more ubiquitous #8

Workflow file for this run

name: PR Build
on:
pull_request:
branches: [main]
paths-ignore:
- "**.md"
- "LICENSE"
issue_comment:
types: [created]
jobs:
isCodeOwner:
if: github.event.issue.pull_request && contains(github.event.comment.body, '/test-pack')
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Check if comment author is a code owner
id: check
run: |
CODEOWNERS=$(cat .github/CODEOWNERS)
COMMENT_AUTHOR=${{ github.event.comment.user.login }}
if echo "$CODEOWNERS" | grep -q "$COMMENT_AUTHOR"; then
echo "::set-output name=isCodeOwner::true"
else
echo "::set-output name=isCodeOwner::false"
fi
build-release:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.x
- name: dotnet build
run: dotnet build -c release
- name: dotnet publish
if: steps.isCodeOwner.outputs.isCodeOwner == 'true'
run: dotnet publish -o pub -c release -p:PublishSingleFile=true -p:Version=${{ env.APP_VERSION }}
- name: Upload binaries
if: steps.isCodeOwner.outputs.isCodeOwner == 'true'
uses: actions/upload-artifact@v4
with:
name: binaries
path: pub/FileSorter.*
choco-pack:
needs: build-release
if: steps.isCodeOwner.outputs.isCodeOwner == 'true'

Check failure on line 54 in .github/workflows/pr-build.yaml

View workflow run for this annotation

GitHub Actions / PR Build

Invalid workflow file

The workflow is not valid. .github/workflows/pr-build.yaml (Line: 54, Col: 9): Unrecognized named-value: 'steps'. Located at position 1 within expression: steps.isCodeOwner.outputs.isCodeOwner == 'true'
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Download a single artifact
uses: actions/download-artifact@v4
with:
name: binaries
path: bin
- name: Package
run: cd choco && choco pack --version ${{ env.APP_VERSION }}
- name: Upload nupkg
uses: actions/upload-artifact@v4
with:
name: nupkg
path: choco/*.nupkg
build-debug:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.x
- name: dotnet build
run: dotnet build -c debug