I have a powershell module with a base class that derives from cmdlet and all of my cmdlets derive from that. Import-module cannot see any of my classes that indirectly derive from cmdlet. Do I need to add a manifest to support this structure.
It's likely one of both of the following problems:
public
[CmdletAttribute]
Here's a minimal, functioning cmdlet:
[Cmdlet(Verb = VerbsCommon.Get, Noun = "Answer")]
public class GetAnswerCommand : PSCmdlet {
public override void EndProcessing() {
WriteObject(42);
}
}
Use import-module
with -verbose
to see information about what's visible. For binary modules, you do not need a manifest (psd1).