Files
claudetools/temp-get-sync-config.ps1

7 lines
381 B
PowerShell

$password = ConvertTo-SecureString 'Paper123!@#' -AsPlainText -Force
$cred = New-Object System.Management.Automation.PSCredential('INTRANET\sysadmin', $password)
Invoke-Command -ComputerName 192.168.0.6 -Credential $cred -ScriptBlock {
Get-Content 'C:\Shares\test\scripts\Sync-FromNAS.ps1' | Select-Object -First 100 | Select-String -Pattern "NAS_|scp|192.168" -Context 1,1
}