Skip to content

devlooped/actions-dotnet-env

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

>_ dotnet-env

Automatically setup .NET environment for actively used SDK versions

Usage

The action is typically used in combination with which-dotnet to keep the CI environment up-to-date with evolving .NET versions used in your repository projects.

If no previously persisted JSON file is provided, automatic discovery of used .NET SDK versions will be performed using which-dotnet.

It's recommended you set up a separate workflow that keeps a dotnet.json file up-to-date to speed-up your builds by avoiding dynamic discovery on every build.

Assuming your repository has the dotnet.json file in its default location (under ./.github), or has no versions file at all:

on:
  push:

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - name: 🤘 checkout
        uses: actions/checkout@v4

      - name: ⚙ dotnet
        uses: devlooped/actions-dotnet-env@v1

      - name: 🙏 build
        run: dotnet build

If you use a different location for the versions file:

  - name: ⚙ dotnet
    uses: devlooped/actions-dotnet-env@v1
    with:
      versions: ./dotnet-versions.json

In order to bootstrap the initial dotnet.json file, you can run the dotnet-env tool with the -o parameter, which initializes it at the default location ./.github/dotnet.json.

Sponsors

Clarius Org MFB Technologies, Inc. Torutek DRIVE.NET, Inc. Keith Pickford Thomas Bolon Kori Francis Toni Wenzel Uno Platform Reuben Swartz Jacob Foshee Eric Johnson David JENNI Jonathan Charley Wu Ken Bonny Simon Cropp agileworks-eu Zheyu Shen Vezel ChilliCream 4OTC Vincent Limo Jordan S. Jones domischell Justin Wendlandt Adrian Alonso Michael Hagedorn Sebastien Lebreton torutek

Sponsor this project  

Learn more about GitHub Sponsors

About

Setup .NET environment

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Sponsor this project

 

Packages

No packages published

Contributors 2

  •  
  •