Using PowerShell instead of STSADM

Since Microsoft is deprecating STSADM, I decided to do deploy a solution using PowerShell (which I like a lot). Microsoft has a nifty STSADM to PowerShell mapping guide, located here (until the link dies).

So for example, to deploy a solution using STSADM, you typically do the following:

Stsadm -o deploysolution -name Microsoft.TeamFoundation.SharePoint.wsp -local -force

To do the same thing using PowerShell cmdlets you’d do the following:

Install-SPSolution -Identity tswawebpartcollection.wsp -WebApplication http://sharepointsitename -local -force

Leave a Reply