It's likely one of both of the following problems:
- The classes are not
public
- The classes are not decorated with
[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).