This project is as start point with .NET framework.
Make sure you have installed all of the following prerequisites on your development machine:
- Visual Studio Community 2019 (https://visualstudio.microsoft.com/fr/downloads/)
- .NET 5 SDK (https://dotnet.microsoft.com/download/dotnet/5.0)
dotnet --version
dotnet --info
You should have .NET Core SDK 5 installed.
git clone https://github.com/bosseludovic/students-union.git && cd students-union
The solution is the projects container. Solutions and projects in Visual Studio
dotnet new sln -n cesi-students-union
dotnet new webAPI -o cesi-students-union -n cesi-students-union
dotnet sln add ./cesi-students-union/cesi-students-union.csproj
cd cesi-students-union
dotnet run
You can now browse to your first route https://localhost:5001/weatherforecast
git clone https://github.com/bosseludovic/students-union.git && cd students-union
dotnet new sln -n cesi-students-union
dotnet new webAPI -o cesi-students-union -n cesi-students-union
dotnet sln add ./cesi-students-union/cesi-students-union.csproj
cd cesi-students-union
dotnet run
https://docs.microsoft.com/fr-fr/dotnet/core/testing/unit-testing-with-dotnet-test
Make sure you're in the root directory
cd ..
dotnet new xunit -o cesi-students-union.Tests -n cesi-students-union.Tests
dotnet add ./cesi-students-union.Tests/cesi-students-union.Tests.csproj reference ./cesi-students-union/cesi-students-union.csproj
dotnet sln add ./cesi-students-union.Tests/cesi-students-union.Tests.csproj
It's time to lauch Visual Studio! You can either run Visual Studio exe and then open you solution file (.sln) or directly run the solution file (.sln) with associated program.
It's the .NET package manager: https://docs.microsoft.com/fr-fr/nuget/quickstart/install-and-use-a-package-in-visual-studio . You can even add package with the nuget package manager or the package manager console.
https://github.com/NLog/NLog/wiki/Getting-started-with-ASP.NET-Core-3
Install-Package NLog.Web.AspNetCore
https://github.com/nlog/NLog/wiki/Configuration-file
Install-Package Swashbuckle.AspNetCore -Version 5.5.0
Install-Package Microsoft.EntityFrameworkCore.SqlServer
Install-Package Microsoft.EntityFrameworkCore.InMemory
Open the SQL server objects (View > SQL Server Object Explorer) Create a new database.
Work with EF Core: https://docs.microsoft.com/fr-fr/ef/core/
Create Models: https://docs.microsoft.com/fr-fr/aspnet/core/data/ef-rp/intro?view=aspnetcore-5.0&tabs=visual-studio
Create a filter on a collection then sort it using linq.
https://docs.docker.com/engine/examples/dotnetcore/
echo. 2>Dockerfile echo. 2>.dockerignore