# encoding: ascii # api: powershell # title: # description: Where-like function works as a pipeline console filter. # version: 0.1 # type: function # license: CC0 # function: Where-Like # x-poshcode-id: 4275 # x-archived: 2013-07-01T01:42:46 # # The idea is to filter a result of any cmdlet with less effort. # I.g. Get-ChildItem ‘C:\Windows’ | Where-Like name explo # function Where-Like { Param($member, $string) process { $input | where {$_.$member -like $string} } }