You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Have you looked at System.CommandLine.Hosting? It provides integration with Microsoft.Extensions.Logging, Microsoft.Extensions.DependencyInjection, etc.
Yeah, I already looked at that. However, my current use case is based on an IWebHostBuilder, which makes System.CommandLine.Hosting out of the question for me.
Activity
jonsequitur commentedon Jun 9, 2020
Have you looked at System.CommandLine.Hosting? It provides integration with Microsoft.Extensions.Logging, Microsoft.Extensions.DependencyInjection, etc.
samtrion commentedon Jun 10, 2020
Yeah, I already looked at that. However, my current use case is based on an
IWebHostBuilder
, which makesSystem.CommandLine.Hosting
out of the question for me.JobaDiniz commentedon Sep 16, 2022
System.CommandLine.Hosting
doesn't seem to exist anymore in the latest beta 4.I was looking at how to inject
ILogger<MyType>
into the handler.KalleOlaviNiemitalo commentedon Sep 16, 2022
@JobaDiniz, https://www.nuget.org/packages/System.CommandLine.Hosting/0.4.0-alpha.22272.1 was built from the same commit 209b724 as https://www.nuget.org/packages/System.CommandLine/2.0.0-beta4.22272.1.
JobaDiniz commentedon Sep 16, 2022
Oh, it's a different nuget package. I wasn't aware of that. Thanks.