pipeline - Alias for "| foreach { "$_" }" in PowerShell -
pipeline - Alias for "| foreach { "$_" }" in PowerShell -
i utilize next code emulate unix "find" behavior:
ls directory -recurse -include pattern | foreach { "$_" } in fact, there couple of other commands i'd append | foreach { "$_" } to. i'm trying find way create easier type. tried stuff this:
function xfind { ls $args | foreach { "$_" } } and invoked so:
xfind directory -recurse -include pattern but seemed wrong thing...
consider utilize -name switch of get-childitem (aka ls, dir):
ls directory -recurse -include pattern -name this way native, clean, , effective.
powershell pipeline
Comments
Post a Comment