3 ms·
Another word of advice: Try to use the pipeline as much as possible. Passing objects through the pipeline is a core concept of PowerShell for a reason. Don't tr
by ygra 13y ago
Another word of advice: Try to use the pipeline as much as possible. Passing objects through the pipeline is a core concept of PowerShell for a reason. Don't try writing C# with PowerShell syntax (as I see so many people do on Stack Overflow).
Some answers I have written on SO that exemplify that:
• http://stackoverflow.com/a/7394766/73070 http://stackoverflow.com/a/7394766/73070
• http://stackoverflow.com/a/1046291/73070 http://stackoverflow.com/a/1046291/73070
• http://stackoverflow.com/a/14481495/73070 http://stackoverflow.com/a/14481495/73070
- doorhammer 12y agoI just glanced at the top post you have linked here (I'll definitely take a look at the others later). At first glance it reminds me of unix pipes, clojure's thrush operator, and F#'s pipe forward operator. (they're all different from one another, of course, but the general idea of threading data through pipes/filter/transformations to get what you want) If I'm not totally missing the mark there, and that's the idiomatic way to do things, I'm glad. I really prefer dealing with scripting/command line stuff that way. Really appreciate the information!