Skip to content

Conversation

@DecSmith42
Copy link
Owner

No description provided.

Copilot AI review requested due to automatic review settings December 9, 2025 15:17
@DecSmith42 DecSmith42 enabled auto-merge December 9, 2025 15:17
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR significantly improves the source generation infrastructure for the DecSm.Atom build system. It consolidates attributes, enhances code generation patterns, and introduces new conveniences for workflow and parameter definitions.

Key changes:

  • Consolidated MinimalBuildDefinitionAttribute into BuildDefinitionAttribute, simplifying the attribute model
  • Introduced GenerateEntryPoint and GenerateSolutionModel attributes for explicit opt-in code generation
  • Refactored source generators to use ForAttributeWithMetadataName for better performance and incremental generation
  • Added WorkflowTargets and Params nested classes for improved API discoverability
  • Changed from SolutionPath to MSBuildProjectDirectory for better solution file discovery
  • Added implicit operators for WorkflowTargetDefinition and ParamDefinition for convenience

Reviewed changes

Copilot reviewed 80 out of 80 changed files in this pull request and generated 14 comments.

Show a summary per file
File Description
_atom/_usings.cs Added global using for DecSm.Atom.Hosting namespace
_atom/_atom.csproj Changed from SolutionPath to MSBuildProjectDirectory compiler-visible property
_atom/Build.cs Updated to use new GenerateEntryPoint, GenerateSolutionModel attributes and WorkflowTargets API
Sample_*/Build.cs Updated sample projects to use new attribute pattern and inherit from BuildDefinition
DecSm.Atom/Workflows/Definition/WorkflowTargetDefinition.cs Added implicit operator from string
DecSm.Atom/Workflows/Definition/Triggers/*.cs Removed empty lines from XML documentation examples
DecSm.Atom/Workflows/Definition/Options/*.cs Removed empty lines from XML documentation examples
DecSm.Atom/Variables/IWorkflowVariableProvider.cs Removed empty line from XML documentation
DecSm.Atom/Util/ServiceStaticAccessor.cs Removed empty line from XML documentation
DecSm.Atom/Secrets/*.cs Removed empty lines from XML documentation examples
DecSm.Atom/Params/ParamDefinition.cs Added implicit operator to string
DecSm.Atom/Hosting/*.cs Removed empty lines from XML documentation examples
DecSm.Atom/DecSm.Atom.targets Simplified and updated to use MSBuildProjectDirectory
DecSm.Atom/DecSm.Atom.props Added global using for Microsoft.Extensions.Logging
DecSm.Atom/DecSm.Atom.csproj Changed .targets PackagePath from "build/" to "buildTransitive/"
DecSm.Atom/Build/Definition/TargetDefinitionAttribute.cs Removed empty line from XML documentation
DecSm.Atom/Build/Definition/MinimalBuildDefinitionAttribute.cs Deleted - consolidated into BuildDefinitionAttribute
DecSm.Atom/Build/Definition/MinimalBuildDefinition.cs Updated documentation to reference BuildDefinitionAttribute
DecSm.Atom.Tests/BuildTests/*/*.cs Updated all test builds to use [BuildDefinition] and explicit base class
DecSm.Atom.SourceGenerators/_usings.cs Removed unused System.Diagnostics.CodeAnalysis global using
DecSm.Atom.SourceGenerators/Parser.cs Deleted - logic moved into GenerateSolutionModelSourceGenerator
DecSm.Atom.SourceGenerators/GenerateSolutionModelSourceGenerator.cs Complete rewrite using ForAttributeWithMetadataName and inline solution parsing
DecSm.Atom.SourceGenerators/GenerateInterfaceMembersSourceGenerator.cs Refactored to use ForAttributeWithMetadataName and improved code organization
DecSm.Atom.SourceGenerators/GenerateEntryPointSourceGenerator.cs Simplified using ForAttributeWithMetadataName
DecSm.Atom.SourceGenerators/BuildDefinitionSourceGenerator.cs Major refactor with better organization, new WorkflowTargets and Params generation
DecSm.Atom.SourceGenerators.Tests/Tests/BuildDefinitionSourceGeneratorTests.cs Updated tests to use [BuildDefinition]
DecSm.Atom.SourceGenerators.Tests/Tests/*.verified.txt Updated verification snapshots to match new generated code format
DecSm.Atom.Module.GithubWorkflows/Extensions.cs Added [PublicAPI] attributes to extension methods
DecSm.Atom.Module.GithubWorkflows.Tests/Workflows/*.cs Updated to use [BuildDefinition] and WorkflowTargets API
DecSm.Atom.Module.Dotnet/DecSm.Atom.Module.Dotnet.props Added global using for DecSm.Atom.Module.Dotnet.Helpers
DecSm.Atom.Module.DevopsWorkflows.Tests/Workflows/*.cs Updated to use [BuildDefinition] and WorkflowTargets API
DecSm.Atom.DotnetCliGenerator/Build.cs Updated to use [BuildDefinition] attribute
Comments suppressed due to low confidence (4)

DecSm.Atom.Tests/BuildTests/BuildInfo/BuildInfoBuild.cs:20

  • Downcasting 'this' from IBuildInfoTarget to BuildInfoBuild introduces a dependency cycle between the two types.
    DecSm.Atom.Tests/BuildTests/BuildInfo/BuildInfoBuild.cs:21
  • Downcasting 'this' from IBuildInfoTarget to BuildInfoBuild introduces a dependency cycle between the two types.
    DecSm.Atom.Tests/BuildTests/BuildInfo/BuildInfoBuild.cs:22
  • Downcasting 'this' from IBuildInfoTarget to BuildInfoBuild introduces a dependency cycle between the two types.
    DecSm.Atom.Tests/BuildTests/BuildInfo/BuildInfoBuild.cs:23
  • Downcasting 'this' from IBuildInfoTarget to BuildInfoBuild introduces a dependency cycle between the two types.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@DecSmith42 DecSmith42 merged commit 5b03b4a into main Dec 9, 2025
34 of 36 checks passed
@DecSmith42 DecSmith42 deleted the improvement/source-gen-improvements branch December 9, 2025 15:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant