Rachaels Spring Weight Loss Diary |
We hope that you enjoyed this Celeb Update
to stop further messages - write Update Notice Messages
118 Kecks Lane - Ruff Dale- Pennsylvania- 1 5 6 7 9 or visit Here
don't see how that follows at all. I like shell scripting because it's , and runs on all my computers. As Stroustrup said, "It will take a lot to persuade me that the world needs yet another proprietary language...especially [one]...closely integrated with a specific proprietary shell scripting and I tolerate PowerShell. It's commands and syntax are atrocious. Horribly long commands and options without any useful command completion. Or if there is I haven't found it. Too many features crammed into single commands that should be separated out. Weird variable and escape syntax only a DOS batch programmer could love. - You are right about not having found stuff. All commands have aliases, and many of them match both DOS and UNIX commands ( ps, dir, rm, ls, kill, history, man, cat, clear etc.) The names are long so that they have a meaningful name. Great for scripts -it helps when a new person has to use and maintain it. There is tab expansion for cmdlets, functions, variable, path, parameters etc. Much of the syntax is from Unix shells and what escape syntax are you talking about? `` is not used for escape since it is the path separator in Windowswrite-output "this is a ""test""". Really, double the character to get two of them. But to output a string without interpreting a variable you use a back-tick. Lack of consistency? Yes. Hard to remember? Yes. Sometimes you have to use a -LiteralPath argumentZan Lynx - Your arguments are not valid. To stop interpreting variables, use ' (single quotes). To the double double quotes thing - same, use write-output 'this is a "test"'. The question you are pointing to is for Regex and the escaping for regex is valid everywhere. Powershell has Here-Strings / verbatim strings as well. Even Java doesn't have these Try escaping regex in Java. And you don't sometimes use literalpath. You use when you need to. LiteralPath treats wildcard characters verbatim and doesn't expand them. You use it when your files have it. It gives you more options. Compared to the bash shell, Powershell is full of inconsistencies that make no sense and are just confusing. In bash you use the same escape character everywhere and file paths are escaped just as strings are. You don't need a special parameter for it. If you expand a variable that has special characters in it, you put it in double quotes and the contents are safe, no need to call a function to re-escape it. - There are no inconsistencies. Even write-output "this you so that you don't miss escaping stuff. It is not necessary to use it. You are thinking that additional options that are there to help you and prevent mistakes are inconsistencies.Yeah, I guess when I'm talking about Unix "shell" I'm also referring to all the normal utilities that come with Unix, such as grep, awk, etc. I'm just wondering if PowerShell offers similar utilities out-of-the-box.s not "just a shell". It is a scripting language. I wonder in what way it is not comparable to perl? I admit that it isn't as mature, but beyond that I don't see the disparity. similar, but I was wondering more about the specific capabilities of PowerShell vs. bash/perl/other unix shells/scripting languages. has an incredibly wide range of functions. It is - A interactive, composable shell - A rich interactive scripting language - A programming language It has a rich set of OO & tesxt utility functions (i.e. equivalents to grep/awk/etc) as well. Jeffrey SnoverI understood Devio to say that powershell is not as powerful as Perl. I don't believe that is true and I just wondered why he thought that was the casea very good point. You will find lots of posts on how to unzip or download a file via http in powershell. While you can do it, that isnt its strength. You are better off calling an exe for that. That of it as batch, but much impr would tend to agree with the notion that PowerShell is primarily a shell. I've done some build and deployment scripting in PowerShell, and I've found that as my scripts got larger, PowerShell as a language didn't handle the growth very well. My code got rather clumsy looking and hard to maintain. That said, this may also be true of bash and any other sh derivatives. PowerShell is superior to cmd for small scripts, but beyond something relatively simple, I would prefer something full blown like Python. (I guess I might be "doing it wrong", but a high learning curve is a strike in my book.)
No comments:
Post a Comment