dotnet / dotnet/msbuild

[Feature Request]: Handle custom targets in `dotnet build -tl`

Open
#8,875 6 comments 1 reaction 1 assignee Claimed by @baronfel View on GitHub
Area: Terminal Logger Feature Request gathering-feedback triaged
Dominant language
C#
Stars
5.5k
Forks
1.5k
Avg merge
1d 8h
Merged PRs (30d)
141

Description

### Summary

`dotnet build -tl` is currently unable to report output of custom targets that are part of a project. It would be great if we could get any kind of information of what is currently being executed instead of being left in the dark.

### Background and Motivation

I have a project which does a handful of things in `PreBuild` and `PostBuild` targets. These commands' (`Exec`) output are displayed when using `dotnet build`, but are entirely omitted when using `dotnet build -tl`, instead only showing `MyProject PreBuild (0.0s)`.

I would like to get progress reports on my commands. Some of them are `dotnet publish` commands for Native AOT, which I would like to monitor.

### Proposed Feature

Something akin to the following output should be enough (taking the previous `dotnet publish` example):

```
MyProject PreBuild (0.0s)
-> Generating native code...
```
```
MyProject PreBuild (0.0s)
-> Creating library /path/to/artifacts/MyProject.NAOT.lib and object /path/to/artifacts/MyProject.NAOT.exp...
```

### 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.