In Powershell you can use the pipe symbol “|” to chain certain commands together. This enables you to make powerful scripts. One example how you can use this is to recursively copy files from one location to another, but exclude certain files based on the filename or extension. Example 1: copy all files from one… Continue reading Powershell copy files from directory excluding certain extensions
Category: File operations
How to delete files with Powershell
1. Delete a folder and everything in it With Powershell you can easily delete folders and files with the command line. Use the snippet below to first check if the folder exists, and if it does, delete it. Note: it is always a good practice to check if the folder exists before trying to delete… Continue reading How to delete files with Powershell