Control a computer via Powershell

Just a simple script to control a machine via powershell.

#Set computername to control
$pc = "[Computername]"
#Trust the host because we are not in the same domain
set-item wsman:\localhost\Client\TrustedHosts -value $pc -force
#Enter the session
Enter-PSSession $pc -Credential $pc\Administrator