Skip to content

Commit 89cf5dd

Browse files
Merge pull request #6 from TimeWarpEngineering/Cramer/2025-10-25/dev
Modernize library with .NET 10, fluent API, and ConfigurationKey attribute
2 parents da90a35 + 962a36a commit 89cf5dd

35 files changed

+932
-549
lines changed

.config/dotnet-tools.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,14 @@
33
"isRoot": true,
44
"tools": {
55
"fixie.console": {
6-
"version": "3.4.0",
6+
"version": "4.1.0",
77
"commands": [
88
"fixie"
99
],
1010
"rollForward": false
1111
},
1212
"dotnet-outdated-tool": {
13-
"version": "4.6.1",
13+
"version": "4.6.8",
1414
"commands": [
1515
"dotnet-outdated"
1616
],

.editorconfig

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,9 @@ root = true
88
#### Core EditorConfig Options ####
99

1010
# So code cleanup will not run on save.
11-
[_Imports.cs]
11+
[_*.cs]
1212
generated_code = true
13+
dotnet_diagnostic.TWA001.severity = none
1314

1415
[*.csproj]
1516
generated_code = true
@@ -255,6 +256,9 @@ dotnet_naming_style.local_function_style.capitalization = pascal_case
255256
#### Analyizer settings ####
256257
dotnet_code_quality.null_check_validation_methods = NotNull
257258

259+
# TWA001: Enforce kebab-case naming convention
260+
dotnet_diagnostic.TWA001.severity = warning
261+
258262
# CA1062: Validate arguments of public methods
259263
# TODO: Turn this back on when figure out how to get Dawn.Guard to not trigger it.
260264
dotnet_diagnostic.CA1062.severity = silent

.github/workflows/ci-build.yml

Lines changed: 0 additions & 54 deletions
This file was deleted.

.github/workflows/ci-cd.yml

Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
name: NuGet Publish
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
paths:
8+
- 'source/**'
9+
- 'tests/**'
10+
- '.github/workflows/**'
11+
- 'Directory.Build.props'
12+
- 'Directory.Packages.props'
13+
pull_request:
14+
branches:
15+
- master
16+
paths:
17+
- 'source/**'
18+
- 'tests/**'
19+
- '.github/workflows/**'
20+
- 'Directory.Build.props'
21+
- 'Directory.Packages.props'
22+
release:
23+
types: [published] # Triggered when a release is published via GitHub Releases UI or gh CLI
24+
workflow_dispatch:
25+
inputs:
26+
version:
27+
description: 'Version to publish (e.g., 1.0.0-beta.3)'
28+
required: false
29+
type: string
30+
31+
jobs:
32+
build-and-publish:
33+
runs-on: ubuntu-latest
34+
steps:
35+
- name: Checkout repository
36+
uses: actions/checkout@v4
37+
with:
38+
fetch-depth: 0
39+
40+
- name: Setup .NET
41+
uses: actions/setup-dotnet@v4
42+
with:
43+
dotnet-version: '10.0.x'
44+
45+
- name: Create artifacts directory
46+
run: mkdir -p artifacts/packages
47+
48+
- name: Build
49+
run: dotnet build --configuration Release
50+
51+
- name: Test
52+
run: |
53+
cd tests/timewarp-options-validation-tests
54+
dotnet tool restore
55+
dotnet restore
56+
dotnet fixie --configuration Release
57+
58+
- name: Publish to NuGet.org (Releases only)
59+
if: github.event_name == 'release' || (github.event_name == 'workflow_dispatch' && github.event.inputs.version != '')
60+
run: |
61+
# Get version from either release tag or manual input
62+
if [ "${{ github.event_name }}" == "release" ]; then
63+
VERSION="${{ github.event.release.tag_name }}"
64+
VERSION="${VERSION#v}" # Remove 'v' prefix if present
65+
else
66+
VERSION="${{ github.event.inputs.version }}"
67+
fi
68+
69+
echo "Publishing version: $VERSION"
70+
71+
dotnet nuget push artifacts/packages/TimeWarp.OptionsValidation.$VERSION.nupkg \
72+
--api-key ${{ secrets.PUBLISH_TO_NUGET_ORG }} \
73+
--source https://api.nuget.org/v3/index.json \
74+
--skip-duplicate
75+
env:
76+
DOTNET_NUGET_SIGNATURE_VERIFICATION: false
77+
78+
- name: Upload Artifacts
79+
uses: actions/upload-artifact@v4
80+
with:
81+
name: Packages-${{ github.run_number }}
82+
path: artifacts/packages/*.nupkg

.github/workflows/release-build.yml

Lines changed: 0 additions & 108 deletions
This file was deleted.

.vscode/settings.json

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
"workbench.colorCustomizations": {
3+
"activityBar.activeBackground": "#f58b87",
4+
"activityBar.background": "#f58b87",
5+
"activityBar.foreground": "#15202b",
6+
"activityBar.inactiveForeground": "#15202b99",
7+
"activityBarBadge.background": "#e2fde3",
8+
"activityBarBadge.foreground": "#15202b",
9+
"commandCenter.border": "#15202b99",
10+
"sash.hoverBorder": "#f58b87",
11+
"statusBar.background": "#f15e58",
12+
"statusBar.foreground": "#15202b",
13+
"statusBarItem.hoverBackground": "#ed3129",
14+
"statusBarItem.remoteBackground": "#f15e58",
15+
"statusBarItem.remoteForeground": "#15202b",
16+
"titleBar.activeBackground": "#f15e58",
17+
"titleBar.activeForeground": "#15202b",
18+
"titleBar.inactiveBackground": "#f15e5899",
19+
"titleBar.inactiveForeground": "#15202b99"
20+
},
21+
"peacock.remoteColor": "#F15E58"
22+
}

CodeMaid.config

Lines changed: 0 additions & 71 deletions
This file was deleted.

0 commit comments

Comments
 (0)