Skip to content
This repository was archived by the owner on Feb 23, 2021. It is now read-only.

Commit 2999b75

Browse files
author
N. Taylor Mullen
committed
Add --bin-dir option to ResolveTagHelpersCommand.
#48
1 parent df978a6 commit 2999b75

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

src/dotnet-razor-tooling/Internal/ResolveTagHelpersCommand.cs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,10 @@ internal static void Register(CommandLineApplication app)
2828
"-p|--protocol",
2929
"Protocol to resolve TagHelperDescriptors with.",
3030
CommandOptionType.SingleValue);
31+
var binDirectory = config.Option(
32+
"-b|--bin-dir",
33+
"The project's bin directory.",
34+
CommandOptionType.SingleValue);
3135
var project = config.Argument(
3236
"[project]",
3337
"Path to the project.json for the project resolving TagHelperDescriptors.",
@@ -41,7 +45,8 @@ internal static void Register(CommandLineApplication app)
4145
{
4246
var projectFilePath = project.Value;
4347
var projectContext = ResolveProjectContext(projectFilePath);
44-
var assemblyLoadContext = projectContext.CreateLoadContext();
48+
var binDirectoryValue = binDirectory.Value();
49+
var assemblyLoadContext = projectContext.CreateLoadContext(outputPath: binDirectoryValue);
4550
var protocol = protocolOption.HasValue() ?
4651
int.Parse(protocolOption.Value()) :
4752
AssemblyTagHelperDescriptorResolver.DefaultProtocolVersion;

0 commit comments

Comments
 (0)