Skip to content

Commit fea5afe

Browse files
Merge pull request #11 from TimeWarpEngineering/dev
feat: drive CI/CD pipeline through dev-cli workflow command
2 parents fa7f887 + afd5f22 commit fea5afe

25 files changed

Lines changed: 838 additions & 65 deletions

.config/dotnet-tools.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"isRoot": true,
44
"tools": {
55
"fixie.console": {
6-
"version": "4.1.0",
6+
"version": "4.2.0",
77
"commands": [
88
"fixie"
99
],

.envrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
PATH_add bin

.github/release-drafter.yml

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

.github/workflows/workflow.yml

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
name: CI/CD
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
paths:
8+
- 'source/**'
9+
- 'tests/**'
10+
- 'tools/**'
11+
- '.github/workflows/**'
12+
- 'Directory.Build.props'
13+
- 'Directory.Packages.props'
14+
pull_request:
15+
branches:
16+
- master
17+
paths:
18+
- 'source/**'
19+
- 'tests/**'
20+
- 'tools/**'
21+
- '.github/workflows/**'
22+
- 'Directory.Build.props'
23+
- 'Directory.Packages.props'
24+
release:
25+
types: [published] # Triggered when a release is published via GitHub Releases UI or gh CLI
26+
workflow_dispatch:
27+
28+
jobs:
29+
ci:
30+
runs-on: ubuntu-latest
31+
32+
steps:
33+
- name: Checkout repository
34+
uses: actions/checkout@v4
35+
with:
36+
fetch-depth: 0
37+
38+
- name: Setup .NET
39+
uses: actions/setup-dotnet@v4
40+
with:
41+
dotnet-version: '10.0.x'
42+
43+
- name: Run CI Pipeline
44+
run: |
45+
if [ "${{ github.event_name }}" == "release" ] || [ "${{ github.event_name }}" == "workflow_dispatch" ]; then
46+
dotnet run --file tools/dev-cli/dev.cs -- workflow --api-key "${{ secrets.PUBLISH_TO_NUGET_ORG }}"
47+
else
48+
dotnet run --file tools/dev-cli/dev.cs -- workflow
49+
fi
50+
51+
- name: Upload Artifacts
52+
if: always()
53+
uses: actions/upload-artifact@v4
54+
with:
55+
name: Packages-${{ github.run_number }}
56+
path: artifacts/packages/*.nupkg
57+
if-no-files-found: ignore

BannedSymbols.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
2+
T:System.Console;Prefer injecting ITerminal. TimeWarp.Terminal.Terminal static class is available for migration.
3+
T:System.Diagnostics.ProcessStartInfo;Use TimeWarp.Amuru Shell.Builder instead. See the 'amuru' skill for usage patterns.

Directory.Build.props

Lines changed: 10 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
<Project>
2-
1+
<Project>
32
<!-- Custom path definitions for repository structure -->
43
<PropertyGroup Label="Custom Repository Variables">
54
<RepositoryName>timewarp-options-validation</RepositoryName>
@@ -11,19 +10,15 @@
1110
<ArtifactsDirectory>$(RepositoryRoot)artifacts/</ArtifactsDirectory>
1211
<PackagesDirectory>$(ArtifactsDirectory)packages/</PackagesDirectory>
1312
</PropertyGroup>
14-
1513
<!-- MSBuild and NuGet behavior configuration -->
1614
<PropertyGroup Label="MSBuild/NuGet Configuration">
1715
<!-- Output packages to our local feed directory -->
1816
<PackageOutputPath>$(PackagesDirectory)</PackageOutputPath>
19-
2017
<!-- Central package management -->
2118
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
22-
2319
<!-- Suppress .NET preview SDK message -->
2420
<SuppressNETCoreSdkPreviewMessage>true</SuppressNETCoreSdkPreviewMessage>
2521
</PropertyGroup>
26-
2722
<!-- Default language and framework settings for all projects -->
2823
<PropertyGroup Label="Project Defaults">
2924
<TargetFramework>net10.0</TargetFramework>
@@ -33,7 +28,6 @@
3328
<IsPackable>false</IsPackable>
3429
<EnablePreviewFeatures>true</EnablePreviewFeatures>
3530
</PropertyGroup>
36-
3731
<!-- Code quality, analyzers, and warning configuration -->
3832
<PropertyGroup Label="Code Quality and Analysis">
3933
<!-- Treat all warnings as errors -->
@@ -43,17 +37,13 @@
4337
<EnableNETAnalyzers>true</EnableNETAnalyzers>
4438
<AnalysisMode>All</AnalysisMode>
4539
<AnalysisLevel>latest-all</AnalysisLevel>
46-
4740
<!-- Report analyzer diagnostics in build output -->
4841
<ReportAnalyzer>true</ReportAnalyzer>
4942
<CodeAnalysisTreatWarningsAsErrors>true</CodeAnalysisTreatWarningsAsErrors>
50-
5143
<!-- Generate XML documentation files -->
5244
<GenerateDocumentationFile>true</GenerateDocumentationFile>
53-
5445
<!-- Emit compiler generated files for source generators -->
5546
<EmitCompilerGeneratedFiles>true</EmitCompilerGeneratedFiles>
56-
5747
<!-- Suppress specific warnings -->
5848
<!-- CA1014: CLS compliance not required for this library -->
5949
<!-- CA1031: Catch general exceptions (needed for validation error handling) -->
@@ -66,9 +56,8 @@
6656
<!-- CA1852: Seal types (not applicable for test base classes) -->
6757
<!-- CA2007: ConfigureAwait (not needed for console applications and tests) -->
6858
<!-- RCS1102: Make class static (test classes with static methods are discovered by Fixie) -->
69-
<NoWarn>$(NoWarn);CA1014;CA1031;CA1052;CA1515;CA1707;CA1724;CA1812;CA1848;CA1852;CA2007;RCS1102</NoWarn>
59+
<NoWarn>$(NoWarn);CA1014;CA1031;CA1052;CA1515;CA1707;CA1724;CA1812;CA1848;CA1852;CA2007;RCS1102</NoWarn>
7060
</PropertyGroup>
71-
7261
<!-- Code analyzers applied to all projects -->
7362
<ItemGroup Label="Code Analyzers">
7463
<PackageReference Include="Roslynator.Analyzers" PrivateAssets="all" />
@@ -77,5 +66,11 @@
7766
<PackageReference Include="Microsoft.CodeAnalysis.NetAnalyzers" PrivateAssets="all" />
7867
<PackageReference Include="Microsoft.CodeAnalysis.CSharp.CodeStyle" PrivateAssets="all" />
7968
</ItemGroup>
80-
81-
</Project>
69+
<ItemGroup>
70+
<PackageReference Include="Microsoft.CodeAnalysis.BannedApiAnalyzers" PrivateAssets="all" IncludeAssets="runtime; build; native; contentfiles; analyzers; buildtransitive" />
71+
<AdditionalFiles Include="$(MSBuildThisFileDirectory)BannedSymbols.txt" />
72+
</ItemGroup>
73+
<ItemGroup>
74+
<PackageReference Include="TimeWarp.Build.Tasks" PrivateAssets="all" />
75+
</ItemGroup>
76+
</Project>

Directory.Packages.props

Lines changed: 21 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,41 @@
1+
<?xml version="1.0" encoding="utf-8"?>
12
<Project>
23
<!-- MSBuild and NuGet behavior configuration -->
34
<PropertyGroup Label="MSBuild/NuGet Configuration">
45
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
56
</PropertyGroup>
67
<ItemGroup Label="Microsoft Extensions">
7-
<PackageVersion Include="Microsoft.Extensions.Configuration" Version="9.0.10" />
8-
<PackageVersion Include="Microsoft.Extensions.Configuration.Abstractions" Version="9.0.10" />
9-
<PackageVersion Include="Microsoft.Extensions.Configuration.Binder" Version="9.0.10" />
10-
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="9.0.10" />
11-
<PackageVersion Include="Microsoft.Extensions.DependencyInjection.Abstractions" Version="9.0.10" />
12-
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="9.0.10" />
13-
<PackageVersion Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="9.0.10" />
8+
<PackageVersion Include="Microsoft.Extensions.Configuration" Version="10.0.8" />
9+
<PackageVersion Include="Microsoft.Extensions.Configuration.Binder" Version="10.0.8" />
10+
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="10.0.8" />
11+
<PackageVersion Include="Microsoft.Extensions.DependencyInjection.Abstractions" Version="10.0.8" />
12+
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="10.0.8" />
13+
<PackageVersion Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="10.0.8" />
1414
<PackageVersion Include="Shouldly" Version="4.3.0" />
1515
<PackageVersion Include="TimeWarp.Build.Tasks" Version="1.0.0">
1616
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
1717
<PrivateAssets>all</PrivateAssets>
1818
</PackageVersion>
1919
<PackageVersion Include="TimeWarp.SourceGenerators" Version="1.0.0-beta.7" />
2020
</ItemGroup>
21+
<ItemGroup Label="Dev CLI">
22+
<PackageVersion Include="Microsoft.CodeAnalysis.BannedApiAnalyzers" Version="3.3.4" />
23+
<PackageVersion Include="TimeWarp.Nuru" Version="3.0.0-beta.70" />
24+
<PackageVersion Include="TimeWarp.Amuru" Version="1.0.0-beta.34" />
25+
<PackageVersion Include="TimeWarp.Terminal" Version="1.0.0-beta.13" />
26+
</ItemGroup>
2127
<ItemGroup Label="FluentValidation">
22-
<PackageVersion Include="FluentValidation" Version="12.0.0" />
28+
<PackageVersion Include="FluentValidation" Version="12.1.1" />
2329
</ItemGroup>
2430
<ItemGroup Label="Testing">
25-
<PackageVersion Include="FakeItEasy" Version="7.3.1" />
26-
<PackageVersion Include="Fixie" Version="3.4.0" />
27-
<PackageVersion Include="Fixie.TestAdapter" Version="4.1.0" />
28-
<PackageVersion Include="FluentAssertions" Version="8.8.0" />
29-
<PackageVersion Include="MediatR" Version="11.0.0" />
30-
<PackageVersion Include="Microsoft.AspNetCore.Mvc.Testing" Version="6.0.10" />
31+
<PackageVersion Include="Fixie.TestAdapter" Version="4.2.0" />
3132
<PackageVersion Include="TimeWarp.Fixie" Version="3.1.0" />
3233
</ItemGroup>
3334
<ItemGroup Label="Code Analyzers">
34-
<PackageVersion Include="Roslynator.Analyzers" Version="4.14.1" />
35-
<PackageVersion Include="Roslynator.CodeAnalysis.Analyzers" Version="4.14.1" />
36-
<PackageVersion Include="Roslynator.Formatting.Analyzers" Version="4.14.1" />
37-
<PackageVersion Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="9.0.0" />
38-
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp.CodeStyle" Version="4.14.0" />
39-
</ItemGroup>
40-
<ItemGroup Label="Roslyn Analyzer Dependencies">
41-
<PackageVersion Include="Microsoft.CodeAnalysis" Version="4.14.0" />
42-
<PackageVersion Include="Microsoft.CodeAnalysis.Analyzers" Version="4.14.0" />
43-
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp" Version="4.14.0" />
35+
<PackageVersion Include="Roslynator.Analyzers" Version="4.15.0" />
36+
<PackageVersion Include="Roslynator.CodeAnalysis.Analyzers" Version="4.15.0" />
37+
<PackageVersion Include="Roslynator.Formatting.Analyzers" Version="4.15.0" />
38+
<PackageVersion Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="10.0.300" />
39+
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp.CodeStyle" Version="5.3.0" />
4440
</ItemGroup>
45-
</Project>
41+
</Project>

documentation/.gitkeep

Whitespace-only changes.

kanban/archived/.gitkeep

Whitespace-only changes.

0 commit comments

Comments
 (0)