Github Actions Yaml reference
- Refer Here for workflow syntax
Github actions steps or actions
- in github actions step is a low level command and steps can be made reusable with actions Refer Here
I want to build a dotnet application
- This dotnet application will require
- dotnet sdk to build
- dotnet runtime to run
- The project is Refer Here
- Dotnet largely has two flavors
- Dotnet
- Dotnet core
- This project requires dotnet core 10
-
dotnet build process
- dotnet has build (compile) and publish (ensure all artifcats are at one location)
- configuration:
- Debug
- Release
-
Steps
- clone the project
git clone https://github.com/Azure-Samples/dotnetcore-docs-hello-world.git -
Install dotnet core 10 on ubuntu 24.04
Search for Installing dotnet core sdk 10.0 on ubuntu and give me sources -
dotnet build –configuration Release
- dotnet publish –configuration Release
-o
- clone the project
- steps
git clone https://github.com/Azure-Samples/dotnetcore-docs-hello-world.git
cd dotnetcore-docs-hello-world/
dotnet build --configuration Release dotnetcoresample.csproj
# tests are missing
dotnet publish --configuration Release -o ./published/ dotnetcoresample.csproj
tar -cvzf dotnetcoresample.tar.gz ./published/
- How can i do this in github actions
- Create a new folder
.github/workflows - Create a file with anyname with extension
.ymlor.yaml
build.yml
- Now we need to understand options, configure runner and write steps.
