Last-modified: 2013-02-11 (月) 00:03:34
PowerShell/再帰かつ正規表現でファイル名を検索したい

概要

再帰的に正規表現でファイル名を検索したい

方法

Everything is expanded.Everything is shortened.
  1
  2
  3
  4
 
 
-
!
ls <検索ルートパス> -recurse | Select-Object fullname | Select-String <正規表現>
 
# 例. 現在のカレント以下にあるbin\*.exeのパスを表示
ls -recurse | Select-Object fullname | Select-String bin\\.*\.exe

検証時の環境