Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
copy docx files for testing
$sourceDir = "\\path\to\source\"
$destDir = "\\path\to\dest\"
# NOTE: this WILL overwrite existing docs (unless open)
Copy-Item $sourceDir*.docx $destDir
# delete (hidden, leftover) office temp files
# usually caused by killing processes
Remove-Item ~*.docx -force
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment