Cloud.Ready.Software.PowerShell icon indicating copy to clipboard operation
Cloud.Ready.Software.PowerShell copied to clipboard

Use of Unapproved Verbs

Open MarkNavGS opened this issue 7 years ago • 8 comments

Do you have plans to address this?

WARNING: The names of some imported commands from the module 'Cloud.Ready.Software.Windows' include unapproved verbs that might make them less discoverable. To find the commands with unapproved verbs, run the Import-Module command again with the Verbose parameter. For a list of approved verbs, type Get-Verb.

MarkNavGS avatar Aug 07 '18 14:08 MarkNavGS

I wasn't planning to address this, actually. You think it's necessary?

waldo1001 avatar Aug 07 '18 14:08 waldo1001

I would argue that it is. What you could do in order not to break scripts that use your module is give the cmdlets a proper name with an approved verb, and specify the old name as an alias.

Alternatively, give the cmdlets a proper name with an approved verb, and lets your users create their aliases locally?

jhoek avatar Feb 18 '19 10:02 jhoek

Hm, that's actually a good idea... I'll experiment with that

waldo1001 avatar Feb 18 '19 11:02 waldo1001

... when I find the time ... ;-)

waldo1001 avatar Feb 18 '19 11:02 waldo1001

Is this planned to be fixed in the future? I understand it is probably quite a low priority. I am using the "Import-NAVModules" function quite a lot in my scripts and it would be nice to suppress the warnings, even if it is just for this function.

nickrobbo avatar Apr 15 '19 12:04 nickrobbo

@nickrobbo ImportModule does have a -DisableNameChecking parameter... ;-)

jhoek avatar Apr 15 '19 13:04 jhoek

@jhoek yes this works with Import-Module, but not with the command I am using:

"Import-NAVModules" - "PSModules/Cloud.Ready.Software.NAV/Import-NAVModules.ps1"

although I can see that this parameter is used within the function, so I am not sure why this happens.

nickrobbo avatar Apr 15 '19 13:04 nickrobbo

@nickrobbo I see. :-)

jhoek avatar Apr 15 '19 15:04 jhoek