Start from a new PowerShell Window:Create a Site Collection:$site = New-SPSite –Url http://sps.adventureworks.com –Template “CMSPUBLISHING#0” –Name “SharePoint Saturday Cincinnati” –OwnerAlias isg1085\\spfarm –SecondaryOwnerAlias isg1085\\sharepointryan –Verbose$site | gm$web = $site.rootweb$web.title = “Modified”$web.update()Get-History | Out-File c:\\scripts\\demo.ps1
Create a script first, then talk about making it reusable by adding parameters and making it a functionCreate a dummy function on the shell to show how they work, then move into PowerGUIAdd some output with Write-HostAdd comment-based help
Show and talk through the XML fileShow and talk through the actual function line by lineRun the functionShow the sites