Skip to content

Commit 6371386

Browse files
code cleanup (#305)
* Updated lps settings * updated editor config * ran code cleanup to get files in sync with the general rules * make cancellation tests more reslient for failure * Updated tools and remove grm (global tool is used elsewhere) * Updated readme * Update azure-pipelines Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
1 parent 6c3a7fc commit 6371386

File tree

1,024 files changed

+15629
-13716
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,024 files changed

+15629
-13716
lines changed

.azure-pipelines.yml

+93-109
Original file line numberDiff line numberDiff line change
@@ -1,123 +1,107 @@
11
trigger:
2-
batch: true
3-
branches:
4-
include:
5-
- master
6-
- refs/tags/*
7-
paths:
8-
exclude:
9-
- '**/*.md'
10-
- '.appveyor.yml'
11-
- '.codecov.yml'
12-
- 'GitVersion.yml'
13-
- 'GitReleaseManager.yaml'
14-
- .vscode/*
15-
- .git*
16-
- .editorconfig
17-
- .nuke
18-
- LICENSE
2+
batch: true
3+
branches:
4+
include:
5+
- master
6+
- next
7+
- refs/tags/*
8+
paths:
9+
exclude:
10+
- '**/*.md'
11+
- '.appveyor.yml'
12+
- '.codecov.yml'
13+
- 'GitVersion.yml'
14+
- 'GitReleaseManager.yaml'
15+
- .vscode/*
16+
- .git*
17+
- .editorconfig
18+
- .nuke
19+
- LICENSE
1920

2021
pr:
21-
autoCancel: true
22-
branches:
23-
include:
24-
- master
22+
autoCancel: true
23+
branches:
24+
include:
25+
- master
26+
- next
2527

2628
resources:
27-
repositories:
28-
- repository: rsg
29-
type: github
30-
name: RocketSurgeonsGuild/AzureDevopsTemplates
31-
ref: refs/tags/v0.12.0
32-
endpoint: github
29+
repositories:
30+
- repository: rsg
31+
type: github
32+
name: RocketSurgeonsGuild/AzureDevopsTemplates
33+
ref: refs/tags/v0.13.0
34+
endpoint: github
3335

3436
variables:
35-
- name: CONFIGURATION
36-
value: Release
37-
- name: VERBOSITY
38-
value: Normal
39-
- name: COVERAGE
40-
value: '$(Agent.BuildDirectory)/c'
41-
- name: ARTIFACTS
42-
value: $(Build.ArtifactStagingDirectory)
43-
- name: DOTNET_SKIP_FIRST_TIME_EXPERIENCE
44-
value: 'true'
45-
- name: CodeCovToken
46-
value: 'd122bf99-4ca6-4a7c-a7ff-90468bcc7703'
47-
# Fixes the github package repo warnings on restore
48-
- name: EmitAssetsLogMessages
49-
value: false
50-
- name: HideWarningsAndErrors
51-
value: true
37+
- name: CONFIGURATION
38+
value: Release
39+
- name: VERBOSITY
40+
value: Normal
41+
- name: COVERAGE
42+
value: '$(Agent.BuildDirectory)/c'
43+
- name: ARTIFACTS
44+
value: $(Build.ArtifactStagingDirectory)
45+
- name: DOTNET_SKIP_FIRST_TIME_EXPERIENCE
46+
value: 'true'
47+
- name: CodeCovToken
48+
value: 'd122bf99-4ca6-4a7c-a7ff-90468bcc7703'
5249

5350
jobs:
54-
- template: jobs/gitversion.yml@rsg
51+
- template: jobs/publish-release.yml@rsg
52+
parameters:
53+
GitHubPackages: false
54+
PublishNuGetPackagesFromArtifact: 'NuGet - Windows'
5555

56-
- job: Build
57-
strategy:
58-
matrix:
59-
Windows:
60-
BuildName: 'Windows'
61-
ImageName: 'windows-latest'
62-
Linux:
63-
BuildName: 'Linux'
64-
ImageName: 'ubuntu-latest'
65-
macOS:
66-
BuildName: 'macOS'
67-
ImageName: 'macOS-latest'
68-
pool:
69-
vmImage: $(ImageName)
70-
steps:
71-
- template: support/mono.yml@rsg
72-
- template: support/install-dotnet.yml@rsg
73-
parameters:
74-
DotNetSdk:
75-
- '2.x'
76-
- '3.x'
77-
- template: support/gitversion-hack.yml@rsg
56+
- job: Build
57+
strategy:
58+
matrix:
59+
Windows:
60+
BuildName: 'Windows'
61+
ImageName: 'windows-latest'
62+
Linux:
63+
BuildName: 'Linux'
64+
ImageName: 'ubuntu-latest'
65+
macOS:
66+
BuildName: 'macOS'
67+
ImageName: 'macOS-latest'
68+
pool:
69+
vmImage: $(ImageName)
70+
steps:
71+
- template: support/mono.yml@rsg
72+
# - ${{ if startsWith(variables['Build.SourceBranch'], 'refs/tags/v') }}:
73+
# - template: support/download-release-notes.yml@rsg
74+
- template: support/install-dotnet.yml@rsg
75+
parameters:
76+
DotNetSdk:
77+
- '2.x'
78+
- '3.x'
7879

79-
- task: DotNetCoreCLI@2
80-
displayName: 'dotnet tool restore'
81-
inputs:
82-
command: custom
83-
custom: tool
84-
arguments: 'restore'
80+
- task: DotNetCoreCLI@2
81+
displayName: 'dotnet tool restore'
82+
inputs:
83+
command: custom
84+
custom: tool
85+
arguments: 'restore'
8586

86-
- task: DotNetCoreCLI@2
87-
displayName: 'dotnet restore'
88-
inputs:
89-
command: restore
90-
feedsToUse: config
91-
nugetConfigPath: NuGet.config
92-
verbosityRestore: Minimal
87+
- task: DotNetCoreCLI@2
88+
displayName: 'dotnet restore'
89+
inputs:
90+
command: restore
91+
feedsToUse: config
92+
nugetConfigPath: NuGet.config
93+
verbosityRestore: Minimal
9394

94-
- template: ./azure-pipelines.nuke.yml
95-
parameters:
96-
Artifacts: $(Artifacts)
97-
Configuration: $(Configuration)
98-
Coverage: $(Coverage)
95+
- template: ./azure-pipelines.nuke.yml
96+
parameters:
97+
Artifacts: $(Artifacts)
98+
Configuration: $(Configuration)
99+
Coverage: $(Coverage)
99100

100-
- template: support/publish-artifacts.yml@rsg
101-
parameters:
102-
Artifacts: $(Artifacts)
103-
Configuration: $(Configuration)
104-
Coverage: $(Coverage)
105-
Postfix: ' - $(BuildName)'
106-
PublishVSTest: true
107-
- ${{ if and(or(startsWith(variables['Build.SourceBranch'], 'refs/tags/v'), eq(variables['Build.SourceBranch'], 'refs/heads/master')), ne(variables['System.PullRequest.IsFork'], 'true')) }}:
108-
- job: Publish_NuGet_Packages
109-
displayName: "Publish NuGet Packages"
110-
pool:
111-
vmImage: "windows-latest"
112-
dependsOn:
113-
- Build
114-
steps:
115-
- checkout: none
116-
- download: current
117-
displayName: "Download NuGet Packages"
118-
artifact: 'NuGet - Windows'
119-
- template: support/nuget-push.yml@rsg
120-
parameters:
121-
Artifacts: "$(Pipeline.Workspace)"
122-
GitHubPackages: false
123-
MyGetPackages: true
101+
- template: support/publish-artifacts.yml@rsg
102+
parameters:
103+
Artifacts: $(Artifacts)
104+
Configuration: $(Configuration)
105+
Coverage: $(Coverage)
106+
Postfix: ' - $(BuildName)'
107+
PublishVSTest: true

.build/Build.cs

+22-25
Original file line numberDiff line numberDiff line change
@@ -18,18 +18,18 @@
1818
[MSBuildVerbosityMapping]
1919
[NuGetVerbosityMapping]
2020
public partial class Solution : NukeBuild,
21-
ICanRestoreWithDotNetCore,
22-
ICanBuildWithDotNetCore,
23-
ICanTestWithDotNetCore,
24-
ICanPackWithDotNetCore,
25-
IHaveDataCollector,
26-
ICanClean,
27-
ICanUpdateReadme,
28-
IGenerateCodeCoverageReport,
29-
IGenerateCodeCoverageSummary,
30-
IGenerateCodeCoverageBadges,
31-
IHaveConfiguration<Configuration>,
32-
ICanLint
21+
ICanRestoreWithDotNetCore,
22+
ICanBuildWithDotNetCore,
23+
ICanTestWithDotNetCore,
24+
ICanPackWithDotNetCore,
25+
IHaveDataCollector,
26+
ICanClean,
27+
ICanUpdateReadme,
28+
IGenerateCodeCoverageReport,
29+
IGenerateCodeCoverageSummary,
30+
IGenerateCodeCoverageBadges,
31+
IHaveConfiguration<Configuration>,
32+
ICanLint
3333
{
3434
/// <summary>
3535
/// Support plugins are available for:
@@ -40,31 +40,28 @@ public partial class Solution : NukeBuild,
4040
/// </summary>
4141
public static int Main() => Execute<Solution>(x => x.Default);
4242

43-
[OptionalGitRepository]
44-
public GitRepository? GitRepository { get; }
43+
[OptionalGitRepository] public GitRepository? GitRepository { get; }
4544

4645
private Target Default => _ => _
47-
.DependsOn(Restore)
48-
.DependsOn(Build)
49-
.DependsOn(Test)
50-
.DependsOn(Pack);
46+
.DependsOn(Restore)
47+
.DependsOn(Build)
48+
.DependsOn(Test)
49+
.DependsOn(Pack);
5150

5251
public Target Build => _ => _.Inherit<ICanBuildWithDotNetCore>(x => x.CoreBuild);
5352

5453
public Target Pack => _ => _.Inherit<ICanPackWithDotNetCore>(x => x.CorePack)
55-
.DependsOn(Clean);
54+
.DependsOn(Clean);
5655

57-
[ComputedGitVersion]
58-
public GitVersion GitVersion { get; } = null!;
56+
[ComputedGitVersion] public GitVersion GitVersion { get; } = null!;
5957

6058
public Target Clean => _ => _.Inherit<ICanClean>(x => x.Clean);
6159
public Target Restore => _ => _.Inherit<ICanRestoreWithDotNetCore>(x => x.CoreRestore);
6260
public Target Test => _ => _.Inherit<ICanTestWithDotNetCore>(x => x.CoreTest);
6361

6462
public Target BuildVersion => _ => _.Inherit<IHaveBuildVersion>(x => x.BuildVersion)
65-
.Before(Default)
66-
.Before(Clean);
63+
.Before(Default)
64+
.Before(Clean);
6765

68-
[Parameter("Configuration to build")]
69-
public Configuration Configuration { get; } = IsLocalBuild ? Configuration.Debug : Configuration.Release;
66+
[Parameter("Configuration to build")] public Configuration Configuration { get; } = IsLocalBuild ? Configuration.Debug : Configuration.Release;
7067
}

.build/Configuration.cs

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,4 @@ public class Configuration : Enumeration
88
public static readonly Configuration Release = new Configuration { Value = nameof(Release) };
99

1010
public static implicit operator string(Configuration configuration) => configuration.Value;
11-
}
11+
}

0 commit comments

Comments
 (0)