Open gep13 opened 4 months ago
Some of the above work was completed in the 2.3.0 release of Chocolatey CLI, where we introduced the concept of the Uninstall-ChocolateyPath
CmdLet. At the time, it made sense to convert the Install-ChocolateyPath
Function from PowerShell to a C# CmdLet, so that there was consistency in how they operated. It also gave us the opportunity to test/validate that everything worked as expected within the Chocolatey Licensed Extension, when changing the dependency to use 2.3.0 of CLI.
I have marked this issue as a Breaking Change, as it does have the potential to have an impact on how some other systems work with Chocolatey CLI.
@gep13 since it's been agreed this will be a breaking change, should we put this in the 3.0
milestone?
Before this issue is closed out completely, we should look to update the Chocolatey.PowerShell.dll-help.xml
file in the repository here. And for that to be done, we will need to merge the draft PRs in the docs repository.
I'll add an entry to the task list here to track this as well.
Additionally, I'm checking off Write-FunctionCallLogMessage
for two reasons: first, it is one of the "internal use only" commands that was never meant to be part of the public API, as documented in its help information; second, it has already been incorporated into the ChocolateyCmdlet
functionality and embedded into the BeginProcessing()
override method defined on that base cmdlet.
Checklist
Is Your Feature Request Related To A Problem? Please describe.
Within the Chocolatey Licensed Extension, we extend the functionality that is provided by some of the Chocolatey PowerShell functions, for example for the Package Throttle feature, which means changing how the Get-WebFile function works.
Extending this functionality can be problematic as it deals with switching between PowerShell and C#, and there are no direct entry points to provide this additional functionality.
Describe The Solution. Why is it needed?
We should convert all the Chocolatey PowerShell Functions, i.e. the
Install-ChocolateyPath.ps1
to be a C# CmdLets.This will allow for better inheritance/overloading of Chocolatey functionality within things like the Chocolatey Licensed Extension, as well as providing the necessary entry points to extend the functionality as/when required.
In addition, this will prevent duplication of code between Chocolatey CLI and CLE.
Additional Context
N/A
Related Issues
Chocolatey.PowerShell.dll-help.xml
external help file in this repository after the docs PRs are merged