次のコードがありますが、ケース ブロック内からファイル名にアクセスする方法がわかりません。
Switch -regex (Get-Content -Path C:\Users\Ryan\Desktop\ps-temp\*) {
'\.DEBUG' {
# How to access filename/PSChildName here?
}
}
次のコードがありますが、ケース ブロック内からファイル名にアクセスする方法がわかりません。
Switch -regex (Get-Content -Path C:\Users\Ryan\Desktop\ps-temp\*) {
'\.DEBUG' {
# How to access filename/PSChildName here?
}
}