Welcome to MSDN Blogs Sign in | Join | Help

Eric Kraus' SharePoint/.NET Blog

What the field says about MOSS.

News

  • Subscribe to this blog


    Eric Kraus on Live Messenger




      Disclaimer
      These postings are provided "AS IS" with no warranties and confer no rights. In addition, these postings are my own and do not represent the views of Microsoft.
    PowerShell Cmdlets in SharePoint 2010

    You may have already heard that SharePoint 2010 will ship with a PowerShell provider that contains over 500 cmdlets for you to administer SharePoint. The killer though, is that these commandlets can be executed remotely with PowerShell 2.0 WinRM.  Awesome!  Don’t worry about STSADM, it will still be around to support existing administration scripts and utilities. 

    You can load the PowerShell provider by typing:

    add-pssnapin Microsoft.SharePoint.PowerShell

    Much of what Christian (iLoveSharePoint) and I have worked on in SPoshMod for SharePoint 2007 supports the same pattern as the 2010 provider.  Verb-Noun, with SP prefix.   Get-SPSite, Get-SPWeb, etc.

    What you may not know is that developers can add custom providers and deploy them to SharePoint.  You can do this by using the Microsoft.SharePoint.PowerShell  namespace.  To distinguish a normal PowerShell cmdlet from a SharePoint cmdlet, an new abstract class has been added to the namespace called: SPCmdlet  (other cmdlets inherit directly from PSCmdlet).

    More to come on this topic…

    Posted: Monday, October 19, 2009 1:49 PM by ekraus

    Comments

    No Comments

    Anonymous comments are disabled
    Page view tracker