I have a module xy which has several functions for the end user and several internal helper functions called by functions but not by the end user.
Get-Command -Module xy -CommandType function
lists all functions I have in my module folder (e.g. get-foo
and get-foo_helper
)
Is there a way to hide get-foo_helper
function from the end user who is using:
Get-Command -Module tcaps -CommandType function
One thing I have done is use the verb-noun naming convention for functions I want to export, but leave out the hyphen in helper functions.
Then, export-modulemember *-*
takes care of only exporting what you want to export.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With