Use Powershell ISE for SharePoint 2010
To be able to use the ISE for SharePoint, you can configure it to load the SharePoint cmdlets automatically.
Scot Hillier wrote a great article about it. Read “Setting up PowerShell ISE for SharePoint 2010”.
If you only want to use the SharePoint cmdlets once, you can register them with this two lines:
If ((Get-PSSnapIn -Name Microsoft.SharePoint.PowerShell -ErrorAction SilentlyContinue) -eq $null ) { Add-PSSnapIn -Name Microsoft.SharePoint.PowerShell }