Github Action .Net core

0

Cześć. Mam takie zapytanie :) Staram się nauczyć Github Action (CI) i na start już mam taki bład:

Telemetry
---------
The .NET Core tools collect usage data in order to help us improve your experience. The data is anonymous. It is collected by Microsoft and shared with the community. You can opt-out of telemetry by setting the DOTNET_CLI_TELEMETRY_OPTOUT environment variable to '1' or 'true' using your favorite shell.

Read more about .NET Core CLI Tools telemetry: https://aka.ms/dotnet-cli-telemetry

----------------
Explore documentation: https://aka.ms/dotnet-docs
Report issues and find source on GitHub: https://github.com/dotnet/core
Find out what's new: https://aka.ms/dotnet-whats-new
Learn about the installed HTTPS developer cert: https://aka.ms/aspnet-core-https
Use 'dotnet --help' to see available commands or visit: https://aka.ms/dotnet-cli-docs
Write your first app: https://aka.ms/first-net-core-app
--------------------------------------------------------------------------------------
MSBUILD : error MSB1003: Specify a project or solution file. The current working directory does not contain a project or solution file.
Error: Process completed with exit code 1.

Mój kod yaml wygląda tak:

name: .NET Core

on:
  push:
    branches: [ main ]
  pull_request:
    branches: [ main ]

jobs:
  build:

    runs-on: ubuntu-latest

    steps:
    - uses: actions/checkout@v2
    - name: Setup .NET Core
      uses: actions/setup-dotnet@v1
      with:
        dotnet-version: 3.1.301
    - name: Install dependencies
      run: dotnet restore
    - name: Build
      run: dotnet build --configuration Release --no-restore
    - name: Test
      run: dotnet test --no-restore --verbosity normal

Wydaje mi się że to jest kwestia ułożenia folderów że np komenda

dotnet build --configuration Release --no-restore

wykonuje się w błednym folderze :/
Tutaj jest kod do repo :)
https://github.com/Michal-Warmuz/Forum

2

Ale ogólnie to się wykonuje w głównym folderze twojego repozytorium i jeżeli nie masz tam swojego pliku .sln albo .csproj to musisz go wskazać - np. dotnet build src/MojProjekt.csproj.

1 użytkowników online, w tym zalogowanych: 0, gości: 1