Created
February 4, 2017 17:41
-
-
Save jespernohr/f95821f32969a179289d19ca159a4c78 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
$cred = Get-Credential | |
$s = New-PSSession -ComputerName server1.contoso.com -Credential $cred | |
#Copy files to server | |
Copy-Item -ToSession $s -Path C:\test\test.txt -Destination D:\Test\ | |
#Copy files from server | |
Copy-Item -FromSession $s -Path C:\Temp\test.txt -Destination C:\test\ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment