All your "man" pages belong to us.

I don’t want Carla Schroder to feel like I am throwing hand grenades over to her side of the fence (Linux), but I wanted to point out that PowerShell, the new command shell for Windows does in fact have some pretty good command-line accessible documentation that work in a very similar way to man pages.

With the command shell up all you need to do is type in “help”, and what you actually get back is an information page about how to use the help command, along with a few pages of examples:

The help system is pretty much tied to the various Cmdlet’s that the system has installed. The beauty of that is that you can ask for help for a list of the commands that it supports by typing “help *-*”:

The reason for this consistency is that PowerShell has all commands using a common verb-entity syntax. So if I want to bring up the help on a command – say Get-ChildItem, I would just type in “help get-childitem” and I would get several pages of help back.

Another cool feature is that it understands now to navigate aliases so if I asked for help on the gci command it would have returned the same result (because gci is an alias for Get-ChildItem, as is dir).

Let’s hope that PowerShell has command-line documentation for a long time to come!


2 thoughts on “All your "man" pages belong to us.

  1. mabster

    Not to mention the funky get-command command with parameters “-verb” and “-noun”. So if I want to get a list of all commands that act on “items” I can simply type:

    get-command -noun item

    .. and likewise if I want a list of commands that output stuff I can type:

    get-command -verb out

    That’s very handy for “discoverability” of commands.

    Matt (newly-converted PowerShell fan)

  2. Mitch Denny Post author

    Hi Mabster,

    Yup. I can’t wait to see what they do with future versions of MMC where they will support spitting out PowerShell scripts from all management UI’s. Awesome stuff!

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s