Skip to content
This repository has been archived by the owner on Feb 4, 2019. It is now read-only.

How to create module for pash? #386

Open
ArsenShnurkov opened this issue Jun 21, 2015 · 1 comment
Open

How to create module for pash? #386

ArsenShnurkov opened this issue Jun 21, 2015 · 1 comment
Labels

Comments

@ArsenShnurkov
Copy link

http://www.darkoperator.com/blog/2013/2/19/powershell-basics-extending-the-shell-with-modules-and-snapi.html

is it possible at all? ( yes, probably, since 2015-01-06 - #331 , #332 )

PASH /> get-module all
PASH />  

works, but doesn't show anything...

This tutorial doesn't work:
https://www.simple-talk.com/sysadmin/powershell/an-introduction-to-powershell-modules/

PASH /> New-ModuleManifest
Command 'New-ModuleManifest' not found.
  +CategoryInfo: ObjectNotFound, Reason: ParentContainsErrorRecordException
  +FullyQualifiedErrorId: CommandNotFoundException
PASH />  

PASH /> Get-Module -ListAvailable
No parameter was found that matches the name or alias 'ListAvailable'.
  +CategoryInfo: InvalidArgument, Reason: ParameterBindingException
  +FullyQualifiedErrorId: ParameterNotFound
PASH /> 
@sburnicki
Copy link
Member

Here is a blog entry about what works, and doesn't work yet with our module system:
http://blog.empalis-systems.com/module-support-pash/

We don't have a (graphical) interface to create manifest, yet (as New-ModuleManifest). But you can just write some in an editor, as in this example.
Note that a manifest is optional for simple script & binary modules.

Get-Module -ListAvailable doesn't work yet, as the results of the discussion of #332 haven't been integrated yet, so Pash doesn't know where to look for modules. But this is on my TODO list ;)
For now, you can import modules by using the absolute or relative path to the module location.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants