Skip to content

Instantly share code, notes, and snippets.

@aburok
Created March 25, 2015 09:53
Show Gist options
  • Save aburok/7665c0206d26e6b4dd89 to your computer and use it in GitHub Desktop.
Save aburok/7665c0206d26e6b4dd89 to your computer and use it in GitHub Desktop.
Powershell search files and echo full path
Get-ChildItem "C:\" -Recurse
| Where-Object {$_.extension -eq ".txt" }
| ForEach-Object { Write-Host $_.FullName }
-- OR --
gci "C:\" -re
| ? { $_.extension -eq ".txt" }
| % { echo $_.FullName }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment