Can you something similar to HttpContext.Items which enables sharing data between different methods that work on the InvocationContext?
public class InvocationContext
{
public IDictionary<string, object> Items { get; }
}
My request comes from wanting to break up handling into several steps.
This provides a way to pass data between the steps.
I can imagine, you could also use this to track things like a ConfigurationManager or an IServiceCollection, enabling to implement configuration or dependency injection external to the core System.CommandLine package.
cc @jonsequitur @adamsitnik @KathleenDollard
Can you something similar to HttpContext.Items which enables sharing data between different methods that work on the
InvocationContext?My request comes from wanting to break up handling into several steps.
This provides a way to pass data between the steps.
I can imagine, you could also use this to track things like a
ConfigurationManageror anIServiceCollection, enabling to implement configuration or dependency injection external to the coreSystem.CommandLinepackage.cc @jonsequitur @adamsitnik @KathleenDollard