How do I get the current username in Windows PowerShell?
I found it:
[Environment]::UserName $Env:UserName
There is also:
$Env:UserDomain $Env:ComputerName