test: skip-music-dir #177
This file contains hidden or 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: .NET CI | |
| on: | |
| workflow_dispatch: | |
| pull_request: | |
| branches: | |
| - master | |
| paths: | |
| - '**.cs' | |
| - '**.csproj' | |
| - '**.sln' | |
| - '**/packages.lock.json' | |
| - '.editorconfig' | |
| - '**/global.json' | |
| - '**/nuget.config' | |
| - '.github/workflows/**.yml' | |
| push: | |
| branches: | |
| - master | |
| paths: | |
| - '**.cs' | |
| - '**.csproj' | |
| - '**.sln' | |
| - '**/packages.lock.json' | |
| - '.editorconfig' | |
| - '**/global.json' | |
| - '**/nuget.config' | |
| - '.github/workflows/**.yml' | |
| jobs: | |
| build-and-test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout Repository | |
| uses: actions/checkout@v4 | |
| - name: Setup .NET SDK | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: '10.0.x' | |
| - name: Cache NuGet packages | |
| uses: actions/cache@v4 | |
| with: | |
| path: ~/.nuget/packages | |
| # The cache key invalidates when the lock file changes | |
| key: ${{ runner.os }}-nuget-${{ hashFiles('**/packages.lock.json') }} | |
| restore-keys: | | |
| ${{ runner.os }}-nuget- | |
| - name: Restore Dependencies | |
| run: dotnet restore | |
| - name: Build Project | |
| run: dotnet build --no-restore --configuration Release | |
| - name: Test Project | |
| run: dotnet test --no-build --configuration Release --verbosity normal | |
| format-check: | |
| if: false # disabled: dotnet format has platform-sensitive indentation behavior | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout Repository | |
| uses: actions/checkout@v4 | |
| - name: Setup .NET SDK | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: '10.0.x' | |
| - name: Format code | |
| run: dotnet format --verify-no-changes |