Skip to content

Update dotnet.yml

Update dotnet.yml #77

Workflow file for this run

# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net
name: .NET
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
permissions:
contents: write
jobs:
build:
runs-on: windows-2019
steps:
- uses: actions/checkout@v4
- name: Setup Environment (PR)
if: ${{ github.event_name == 'pull_request' }}

Check failure on line 23 in .github/workflows/dotnet.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/dotnet.yml

Invalid workflow file

You have an error in your yaml syntax on line 23
run: |
echo "LAST_COMMIT_SHA=${{ github.event.pull_request.head.sha }}" >> ${GITHUB_ENV}
- name: Setup Environment (Push)
if: ${{ github.event_name == 'push' }}
run: |
echo "LAST_COMMIT_SHA=${GITHUB_SHA}" >> ${GITHUB_ENV}
- name: Test
run: echo "github sha is ${{ env.LAST_COMMIT_SHA }}"