[alternative syntax]
For some people, directional pipe operators are not their taste, but rather prefer chains. See some interesting opinions on this topic shared by the roslyn tracker: dotnet / roslyn # 5445 .
Based on the case and context, one of these approaches can be considered implicit (or indirect). For example, in this case using pipe fromnumerable requires a special $_ token (aka PowerShell "THIS" token ), which may seem unpleasant for some.
For these guys, this is a more concise, direct way to do this using a chain of points:
(gci . -re -fi *.txt).FullName
(<rant> Note that the PowerShell argument parser accepts partial parameter names. Thus, in addition to -recursive ; -recursiv , -recursi , -recurs , -recur , -recu , -rec and -re , but unfortunately , not -r .., which is the only right choice that makes sense with a single character - (if we follow the POSIXy UNIXy conventions)! </rant>)
vulcan raven Nov 22 '15 at 10:56 2015-11-22 10:56
source share