Powershell - How to insert multiple files content in one file

You can do this with the script below:

$path="\\server\logs\*.txt"

$files = dir $path
foreach ($file in $files){
    Get-Content $file >> c:\tmp\log.txt

}

And get your output file with the content of all other files.

Comments

Popular posts from this blog

Openedge (Progress) - List transaction cache

Windows - Open exe, bat and all other program files from your intranet

Impacket-master - psexec for linux