MSBuildStructuredLog icon indicating copy to clipboard operation
MSBuildStructuredLog copied to clipboard

Change Default Name of Generated Binlogs

Open benvillalobos opened this issue 4 years ago • 3 comments

Consider changing the default msbuild.binlog name to <projectOrSlnName>.binlog.

Scenarios:

  1. For devs that deal with many binlogs, renaming them/placing a name in the command line for each invocation can be a pain.
  2. Improves the "right click->pick binlog" experience for those that collect many binlogs but don't rename them.
  3. Sharing binlogs between any developers.

image

benvillalobos avatar Apr 26 '21 19:04 benvillalobos

This should be on MSBuild I think.

KirillOsenkov avatar Apr 26 '21 20:04 KirillOsenkov

I thought about this, and making this change in MSBuild would be a breaking change unfortunately. Many people have their CI set up with just /bl and they rely by convention on the log file name being msbuild.binlog. I don't think we should risk breaking this at this point.

I, too, wish it used the project/solution name by default instead of fixed msbuild, but this is historically how the text logs behaved. One can argue that there's value in having the name predictable by default (so one can author CI to upload the log for example).

Maybe we could add something like /bl:_ and treat that as "infer binlog name from the project being built". But that's not intuitive.

KirillOsenkov avatar Apr 27 '21 02:04 KirillOsenkov

Maybe we could add something like /bl:_

I'd appreciate something like this but it doesn't sound like there's a way to make it:

  1. Easy to do (some other similar/short flag)
  2. Intuitive

/bln? (binlognamed)

Even then not many people would use it.

Feel free to close, glad I got to grumble about it 🙂

benvillalobos avatar Apr 28 '21 16:04 benvillalobos