19
PowerShell Basics in SharePoint 2010 Corey Roth Stonebridge Twitter: @ coreyroth Blog: www.dotnetmafia.com Just enough to be dangerous Kyle Kelin Infusion Twitter: @ spkyle Blog: www.dotnetmafia.com

Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

Embed Size (px)

DESCRIPTION

Slides from the talk with Corey Roth and Kyle Kelin on PowerShell in SharePoint 2010.

Citation preview

Page 1: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

PowerShell Basics in SharePoint 2010

Corey RothStonebridgeTwitter: @coreyrothBlog: www.dotnetmafia.com

Just enough to be dangerous

Kyle KelinInfusionTwitter: @spkyleBlog: www.dotnetmafia.com

Page 2: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

Welcome to Houston SharePoint Saturday

• Please turn off all electronic devices or set them to vibrate.• If you must take a phone call, please do so in the hall so as not

to disturb others.• Thanks to our Platinum Sponsors:

Thank you for being a part of the first ever SharePoint Saturday for the greater

Houston area!

Page 3: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

Corey RothConsultant for Stonebridge in Tulsa, OKWorked in Consumer Electronics, Travel, Advertising, and Energy industriesCurrently doing SharePoint development specializing in Enterprise SearchMicrosoft Solutions AdvocateMicrosoft Award for Customer Excellence (ACE) WinnerE-mail: [email protected] Twitter: @coreyrothBlog: www.dotnetmafia.com

Page 4: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

Kyle KelinPrincipal Architect at InfusionBuilt applications across multiple industries that include consumer electronics, travel, energy, government, pharmaceuticals, and investment bankingE-mail: [email protected] Twitter: @spkyleBlog: www.dotnetmafia.com

Page 5: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

What is PowerShell?

Page 6: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

Like a command prompt…Only better!Aliases allow familiar MS-DOS and Unix commands to work (i.e.: dir, ls, cd, del)Includes formatting features to display results as lists and tablesPipelining allows results of one command to act as input to another

Page 7: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

What about STSADM?Still present, but why use it?Old scripts should runSTSADM extensions considered deprecated (but they’ll probably work)

Page 8: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

PowerShell Window

Page 9: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

Demo

Page 10: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

PS is perfect for SPSharePoint functionality provided through Microsoft.SharePoint.PowerShell snapinAdd-PSSnapin Microsoft.SharePoint.PowerShellOver 500 commands available

Get-Command Microsoft.SharePoint.PowerShell

Page 11: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

Demo

Page 12: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

Execution PolicyBy default, PowerShell does not allow scripts to runChange policy with Set-ExecutionPoilicyPolicy Settings

Restricted (default) – scripts will not executeUnrestricted – scripts can execute. Unsigned scripts will prompt user to executeBypass (developer mode) – scripts can execute, no user prompting to execute

Page 13: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

Demo

Page 14: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

CmdletsExtend PowerShell using Visual StudioCan be executed in PowerShell as a snapin or module

Page 15: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

Demo

Page 16: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

Questions?

Page 17: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

Session Evaluation• Please complete and turn in

your Session Evaluation Form so we can improve future events.

• Presenter:– Corey Roth / Kyle Kelin

• Session Name:– PowerShell Basics in

SharePoint 2010

Page 18: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

Thanks to our Sponsors

Page 19: Power shell basics in sharepoint 2010 - SharePoint Saturday Houston 2010

Thanks

Corey RothStonebridgeTwitter: @coreyrothBlog: www.dotnetmafia.com

Kyle KelinInfusionTwitter: @spkyleBlog: www.dotnetmafia.com