Created
July 29, 2016 10:43
-
-
Save jespernohr/1c9090419c336e8f6af0bdecc3bb078a to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# | |
.Synopsis | |
Get systeminfo on remote computer | |
.Description | |
These commands save your administrator credentials in a variable and make use of invoke command to run systeminfo on a remote computer | |
#> | |
$cred = Get-Credential | |
Invoke-Command –ScriptBlock {systeminfo} –ComputerName computer1.contoso.com -Credential $cred |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment