Skip to content

Commit 83a33dc

Browse files
authored
Renamed host-basedir to host-rootdir (#791)
1 parent 339173c commit 83a33dc

File tree

4 files changed

+6
-7
lines changed

4 files changed

+6
-7
lines changed

examples/NetCore2/HostingExample/Program.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
using Microsoft.Extensions.Hosting;
77
using Microsoft.Extensions.Logging;
88
using NLog;
9-
using NLog.Extensions.Logging;
109
using NLog.Extensions.Hosting;
1110

1211
namespace HostingExample

src/NLog.Extensions.Hosting/Config/SetupExtensionsBuilderExtensions.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ public static ISetupExtensionsBuilder RegisterHostSettings(this ISetupExtensions
1717
{
1818
setupBuilder.RegisterConfigSettings(configuration);
1919
return setupBuilder.RegisterLayoutRenderer<HostAppNameLayoutRenderer>("host-appname")
20-
.RegisterLayoutRenderer<HostBaseDirLayoutRenderer>("host-basedir")
20+
.RegisterLayoutRenderer<HostRootDirLayoutRenderer>("host-rootdir")
2121
.RegisterLayoutRenderer<HostEnvironmentLayoutRenderer>("host-environment");
2222
}
2323
}

src/NLog.Extensions.Hosting/Extensions/ConfigureExtensions.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ private static void RegisterHostNLogExtensions(LogFactory logFactory, IServicePr
171171
if (hostingEnvironment != null)
172172
ext.RegisterSingletonService(hostingEnvironment);
173173
ext.RegisterLayoutRenderer<HostEnvironmentLayoutRenderer>("host-environment");
174-
ext.RegisterLayoutRenderer<HostBaseDirLayoutRenderer>("host-basedir");
174+
ext.RegisterLayoutRenderer<HostRootDirLayoutRenderer>("host-rootdir");
175175
ext.RegisterLayoutRenderer<HostAppNameLayoutRenderer>("host-appname");
176176
});
177177
}

src/NLog.Extensions.Hosting/LayoutRenderers/HostBaseDirLayoutRenderer.cs renamed to src/NLog.Extensions.Hosting/LayoutRenderers/HostRootDirLayoutRenderer.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,12 @@ namespace Microsoft.Extensions.Hosting
1515
/// Rendering Application Host <see cref="IHostEnvironment.ContentRootPath" />
1616
/// </summary>
1717
/// <remarks>
18-
/// <code>${host-basedir}</code>
18+
/// <code>${host-rootdir}</code>
1919
/// </remarks>
20-
/// <seealso href="https://github.com/NLog/NLog/wiki/Host-BaseDir-layout-renderer">Documentation on NLog Wiki</seealso>
21-
[LayoutRenderer("host-basedir")]
20+
/// <seealso href="https://github.com/NLog/NLog/wiki/Host-RootDir-layout-renderer">Documentation on NLog Wiki</seealso>
21+
[LayoutRenderer("host-rootdir")]
2222
[ThreadAgnostic]
23-
public class HostBaseDirLayoutRenderer : LayoutRenderer
23+
public class HostRootDirLayoutRenderer : LayoutRenderer
2424
{
2525
/// <summary>
2626
/// Provides access to the current IHostEnvironment

0 commit comments

Comments
 (0)