navcontainerhelper icon indicating copy to clipboard operation
navcontainerhelper copied to clipboard

Why not use approved PowerShell verbs - Run vs. Invoke/Start?

Open jhoek opened this issue 4 years ago • 3 comments

Describe the issue To facilitate the learning and discovery process for new users, PowerShell uses a predefined set of verbs for all cmdlets and advanced functions to use. While I really like the new Run-ALValidation and Run-ALPipeline cmdlets, I also really like meaningful standards. :-) Cmdlets that run things should probably use either the Start verb (according to the documentation, "Initiates an operation"), or the Invoke verb ("Performs an action, such as running a command or a method").

Scripts used to create container and cause the issue Get-Verb Run # this exists as an approved verb Get-Verb Invoke # this does not exist as an approved verb

Full output of scripts n/a

Screenshots n/a

Additional context A possible, backwards compatible solution would be to correct the function names, then add the old, flawed name as an alias.

jhoek avatar Dec 29 '20 11:12 jhoek

I am totally aware that BcContainerHelper doesn't live up to high standards of PowerShell. Not only the names, but also the piping and other things. It is in my backlog to change this but I have no ETA.

freddydk avatar Dec 29 '20 14:12 freddydk

OK, thanks. I hope to - some day - find the time to help fix some of those cases in a pull request.

jhoek avatar Dec 29 '20 15:12 jhoek

Maybe we should start by adding an new alias to all command with a wrong verb. so we can do a soft migration. at some day we will change the function name and add the old one as alias and throw a warning if the alias is used. later we will remove the alias (old verb).

ChrisBlankDe avatar May 24 '23 09:05 ChrisBlankDe