Quantcast
Channel: PowerShell.org » All Posts
Viewing all articles
Browse latest Browse all 13067

Reply To: Module Manifest Help

$
0
0

Is there a way to load the sqlps module with disable name checking enabled but keeping the sqlps module local to my modules scope.
- You could load the module from within your script module. That’d give you the ability to only export the commands you want – which can exclude anything in sqlps. Or, you can accomplish the same thing in the manifest, if you prefer.

Is there a way of executing code to initialize the environment after the modules have loaded. ScriptsToProcess seems to execute prior to loading the modules. I want to do this to change the PSDrive.
- Any code in the root module that isn’t in a function will run with the module loads.

Is there a way to include all of the functions, cmdlets etc for export excluding the sqlps ones. I don’t want to expose sqlps I just want to consume it. Currently i am using FunctionsToExport = ‘*’.
- Change FunctionsToExport to include only yours. If you were smart and put a noun prefix on yours, then you can use a partial wildcard.


Viewing all articles
Browse latest Browse all 13067

Trending Articles