Skip to content

Commit d424d3e

Browse files
authored
Update to Steeltoe v4.0-rc1 (#14)
1 parent d3cfffd commit d424d3e

File tree

5 files changed

+12
-16
lines changed

5 files changed

+12
-16
lines changed

Version.props

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,8 @@
55
</PropertyGroup>
66

77
<PropertyGroup>
8-
<SteeltoeVersion>3.2.*</SteeltoeVersion>
8+
<SteeltoeVersion>4.0.0-rc1</SteeltoeVersion>
9+
<SteeltoeUtilsVersion>3.2.8</SteeltoeUtilsVersion>
910
<SwashbuckleVersion>6.5.0</SwashbuckleVersion>
1011
</PropertyGroup>
1112

src/NetCoreToolService/Controllers/NewController.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ public class NewController : ControllerBase
3333

3434
private readonly ILogger<NewController> _logger;
3535

36-
private readonly Dictionary<string, IPackager> _packagers = new ()
36+
private readonly Dictionary<string, IPackager> _packagers = new()
3737
{
3838
{ "zip", new ZipPackager() },
3939
};
@@ -260,7 +260,7 @@ private async Task<TemplateDictionary> GetTemplateDictionary()
260260
var lines = listCommand.Output.Split('\n').ToList()
261261
.FindAll(line => !string.IsNullOrWhiteSpace(line));
262262

263-
var headingIdx = lines.FindIndex(line => line.StartsWith("-"));
263+
var headingIdx = lines.FindIndex(line => line.StartsWith('-'));
264264
var headings = lines[headingIdx].Split(" ");
265265
const int nameColStart = 0;
266266
var nameColEnd = nameColStart + headings[0].Length;

src/NetCoreToolService/Program.cs

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
using Microsoft.AspNetCore.Hosting;
66
using Microsoft.Extensions.Hosting;
7-
using Steeltoe.Extensions.Logging;
7+
using Steeltoe.Logging.DynamicConsole;
88
using Steeltoe.NetCoreToolService.Models;
99
using System.Reflection;
1010

@@ -19,15 +19,11 @@ static Program()
1919
{
2020
var versionAttr =
2121
typeof(Program).Assembly.GetCustomAttribute<AssemblyInformationalVersionAttribute>();
22-
var fields = versionAttr?.InformationalVersion.Split('+');
23-
if (fields is null)
24-
{
25-
fields = new[] { "unknown" };
26-
}
22+
var fields = versionAttr?.InformationalVersion.Split('+') ?? ["unknown"];
2723

2824
if (fields.Length == 1)
2925
{
30-
fields = new[] { fields[0], "unknown" };
26+
fields = [fields[0], "unknown"];
3127
}
3228

3329
About = new About

src/NetCoreToolService/Startup.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
using Microsoft.Extensions.Logging;
1111
using Microsoft.OpenApi.Models;
1212
using Steeltoe.Common.Utils.Diagnostics;
13-
using Steeltoe.Management.Endpoint;
13+
using Steeltoe.Management.Endpoint.Actuators.All;
1414
using System.Text.Json.Serialization;
1515

1616
namespace Steeltoe.NetCoreToolService
@@ -47,7 +47,6 @@ public void ConfigureServices(IServiceCollection services)
4747
});
4848
services.AddTransient<ICommandExecutor, CommandExecutor>();
4949
services.AddAllActuators();
50-
services.ActivateActuatorEndpoints();
5150
services.AddSwaggerGen(c =>
5251
{
5352
c.SwaggerDoc("v1", new OpenApiInfo { Title = "Steeltoe.NetCoreToolService", Version = "v0" });

src/NetCoreToolService/Steeltoe.NetCoreToolService.csproj

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<Project Sdk="Microsoft.NET.Sdk.Web">
22
<PropertyGroup>
3-
<Authors>Steeltoe,VMware</Authors>
3+
<Authors>Steeltoe,Broadcom</Authors>
44
<PublishRepositoryUrl>true</PublishRepositoryUrl>
55
<IncludeSymbols>true</IncludeSymbols>
66
<EmbedUntrackedSources>true</EmbedUntrackedSources>
@@ -23,11 +23,11 @@
2323
</PropertyGroup>
2424

2525
<ItemGroup>
26-
<PackageReference Include="Steeltoe.Management.EndpointCore" Version="$(SteeltoeVersion)" />
27-
<PackageReference Include="Steeltoe.Common.Utils" Version="$(SteeltoeVersion)" />
26+
<PackageReference Include="Steeltoe.Management.Endpoint" Version="$(SteeltoeVersion)" />
27+
<PackageReference Include="Steeltoe.Common.Utils" Version="$(SteeltoeUtilsVersion)" />
2828
<PackageReference Include="Swashbuckle.AspNetCore" Version="$(SwashbuckleVersion)" />
2929
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="8.0.0" PrivateAssets="All" />
30-
<PackageReference Include="StyleCop.Analyzers" Version="1.1.118">
30+
<PackageReference Include="StyleCop.Analyzers" Version="1.2.0-beta.556">
3131
<PrivateAssets>All</PrivateAssets>
3232
</PackageReference>
3333
<AdditionalFiles Include="$(MSBuildThisFileDirectory)\..\..\stylecop.json" />

0 commit comments

Comments
 (0)