Skip to content

Conversation

@JusterZhu
Copy link
Collaborator

No description provided.

@JusterZhu JusterZhu added the refactor Refactor some existing code. label Feb 11, 2026
@JusterZhu JusterZhu marked this pull request as ready for review February 11, 2026 12:25
Copilot AI review requested due to automatic review settings February 11, 2026 12:25
@JusterZhu JusterZhu merged commit 91809af into master Feb 11, 2026
2 checks passed
@JusterZhu JusterZhu deleted the remove_driver branch February 11, 2026 12:25
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 removes the legacy “driver update” implementation from the C# codebase and stops wiring it into the update pipeline, along with cleaning up solution/test artifacts related to that feature.

Changes:

  • Removed DriverMiddleware from the Windows/Linux pipeline builders.
  • Deleted the legacy driver command implementation under GeneralUpdate.Core/Driver (processor, commands, executor, info types).
  • Updated the solution and tests to drop projects/tests associated with the removed driver feature.

Reviewed changes

Copilot reviewed 17 out of 17 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/c#/GeneralUpdate.sln Removes several projects (including the old upgrader/examples) from the solution.
src/c#/GeneralUpdate.Core/Strategys/WindowsStrategy.cs Drops DriverMiddleware from the Windows update pipeline.
src/c#/GeneralUpdate.Core/Strategys/LinuxStrategy.cs Drops DriverMiddleware from the Linux update pipeline.
src/c#/GeneralUpdate.Core/Pipeline/DriverMiddleware.cs Deletes the legacy driver middleware.
src/c#/GeneralUpdate.Core/Driver/*.cs Deletes the legacy driver command/processor implementation.
src/c#/CoreTest/Pipeline/DriverMiddlewareTests.cs Removes tests for the deleted middleware.
src/c#/CoreTest/Driver/*.cs Removes tests for the deleted legacy driver subsystem.

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

Comment on lines +33 to +38
protected override PipelineBuilder BuildPipeline(PipelineContext context)
{
return new PipelineBuilder(context)
.UseMiddlewareIf<PatchMiddleware>(_configinfo.PatchEnabled)
.UseMiddleware<CompressMiddleware>()
.UseMiddleware<HashMiddleware>()
.UseMiddlewareIf<DriverMiddleware>(_configinfo.DriveEnabled);
.UseMiddleware<HashMiddleware>();
Copy link

Copilot AI Feb 11, 2026

Choose a reason for hiding this comment

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

DriverMiddleware was removed from the pipeline, but DriveEnabled is still used earlier in this strategy to populate driver-related context keys (e.g., DriverOutPut, FieldMappings). With no middleware consuming these values anymore, the option becomes a no-op and the extra temp directory setup is dead code. Consider removing the DriveEnabled branch/context keys (and/or the option itself) or wiring DriveEnabled to the new driver update implementation (e.g., Drivelution) so enabling it still has an effect.

Copilot uses AI. Check for mistakes.
Comment on lines +31 to +36
protected override PipelineBuilder BuildPipeline(PipelineContext context)
{
return new PipelineBuilder(context)
.UseMiddlewareIf<PatchMiddleware>(_configinfo.PatchEnabled)
.UseMiddleware<CompressMiddleware>()
.UseMiddleware<HashMiddleware>()
.UseMiddlewareIf<DriverMiddleware>(_configinfo.DriveEnabled);
.UseMiddleware<HashMiddleware>();
Copy link

Copilot AI Feb 11, 2026

Choose a reason for hiding this comment

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

DriverMiddleware was removed from the pipeline, but DriveEnabled is still used earlier in this strategy to populate driver-related context keys (e.g., DriverOutPut, FieldMappings). With no middleware consuming these values anymore, the option becomes a no-op and the extra temp directory setup is dead code. Consider removing the DriveEnabled branch/context keys (and/or the option itself) or wiring DriveEnabled to the new driver update implementation (e.g., Drivelution) so enabling it still has an effect.

Copilot uses AI. Check for mistakes.
Comment on lines 8 to 13
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "GeneralUpdate.Core", "GeneralUpdate.Core\GeneralUpdate.Core.csproj", "{35BFF228-5EE4-49A6-B721-FB0122E967A0}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "GeneralUpdate.ClientCore", "GeneralUpdate.ClientCore\GeneralUpdate.ClientCore.csproj", "{BAEFF926-6B2C-46F1-BB73-AA2AB1355565}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "GeneralUpdate.Differential", "GeneralUpdate.Differential\GeneralUpdate.Differential.csproj", "{40BDA496-7614-4213-92D0-3B1B187675D3}"
EndProject
Copy link

Copilot AI Feb 11, 2026

Choose a reason for hiding this comment

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

This solution removes the GeneralUpdate.Upgrad project, but the project still exists in the repo and currently does not compile after this PR because it still has using GeneralUpdate.Core.Driver; while the entire GeneralUpdate.Core.Driver namespace was deleted. Either remove/retire the GeneralUpdate.Upgrad project from the repository as well, or update it to stop referencing the removed driver APIs so it can still be built independently.

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

refactor Refactor some existing code.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants