dotnet / dotnet/msbuild

Public API for implicit restore

Open
#11,519 1 comment 1 reaction 0 assignees View on GitHub
gathering-feedback Priority:2 triaged
Dominant language
C#
Stars
5.5k
Forks
1.5k
Avg merge
1d 8h
Merged PRs (30d)
141

Description

### Summary

Using MSBuild APIs to do the equivalent of `msbuild.exe -restore` is complicated: https://github.com/dotnet/sdk/blob/fcd9a9224c91132226206ebd15922e42fb3ed483/src/Cli/dotnet/commands/VirtualProjectBuildingCommand.cs#L51-L80

It would be nice to have an API for this instead.

### Background and Motivation

https://github.com/dotnet/msbuild/pull/2414 introduced implicit restore command line argument but no API as far as I can see.

Similar issue for MSBuild Task: https://github.com/dotnet/msbuild/issues/2811

### Proposed Feature

Something like `new BuildRequestData(..., implicitRestore: true)`?

### Alternative Designs

_No response_

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.