<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx</link><description>M ost shells (such as Windows CMD.EXE and the UNIX shells SH, KSH, CSH, and BASH) operate by executing a command or utility in a new process, and presenting the results (or errors) to the user as text. Text-based processing is the way in which system</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>Reflections &amp;raquo; Cool post on MSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#588013</link><pubDate>Tue, 02 May 2006 03:39:26 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:588013</guid><dc:creator>Reflections » Cool post on MSH</dc:creator><description>PingBack from &lt;a rel="nofollow" target="_new" href="http://blog.3deurope.com/index.php/2006/05/01/cool-post-on-msh/"&gt;http://blog.3deurope.com/index.php/2006/05/01/cool-post-on-msh/&lt;/a&gt;</description></item><item><title>Quiddit.ch  &amp;raquo; Blog Archive   &amp;raquo; Windows PowerShell</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#591892</link><pubDate>Sun, 07 May 2006 18:42:42 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:591892</guid><dc:creator>Quiddit.ch  » Blog Archive   » Windows PowerShell</dc:creator><description>PingBack from &lt;a rel="nofollow" target="_new" href="http://www.quiddit.ch/?p=66"&gt;http://www.quiddit.ch/?p=66&lt;/a&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#850373</link><pubDate>Fri, 20 Oct 2006 23:38:57 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:850373</guid><dc:creator>Jan</dc:creator><description>&lt;P&gt;It looks like the PowerShell is an Object Oriented view of System. But still: is there really something new? I thing all that we already saw somewhere around (AmigaOS, unix/linux, MacOS). We have to wait for applications to start support it (implement methods), then it start to be very interesting.&lt;/P&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#904107</link><pubDate>Mon, 30 Oct 2006 21:38:19 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:904107</guid><dc:creator>Dave </dc:creator><description>&lt;p&gt;Isn't the first argument (that 'ps' may behave differently on different systems) silly? Windows is one system, so of course you don't have subtle interoperability problems. 'ps' doesn't work the same for Windows as it does for Unix either; it doesn't work at all! On the other hand, if you're POSIX, this stuff has to work the same way for the same switches (in addition to the vendor's superset of commands for ps, ls, etc)&lt;/p&gt;
&lt;p&gt;Example 3 isn't so good either. One would simply use 'du' in that situation. &lt;/p&gt;
&lt;p&gt;Example 4 really do the same thing the same way; the only difference is notation. Give me the time now and find the difference. Either way, you had to figure out how to get that metric and fetch it twice.&lt;/p&gt;
&lt;p&gt;Example 6 has nothing to do with any Unix shell.&lt;/p&gt;
&lt;p&gt;I'm not saying that PowerShell isn't a step forward (I don't know yet, I plan on playing with it at work...but anything beats cmd or wsh), but these arguments are bogus. &lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1081030</link><pubDate>Wed, 15 Nov 2006 15:30:01 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1081030</guid><dc:creator>Lex</dc:creator><description>&lt;p&gt;Hello,&lt;/p&gt;
&lt;p&gt;Easier way to do...&lt;/p&gt;
&lt;p&gt;Example 1 :&lt;/p&gt;
&lt;p&gt;=&amp;gt; use pkill&lt;/p&gt;
&lt;p&gt;# pkill -9 vi&lt;/p&gt;
&lt;p&gt;[1] &amp;nbsp; Killed &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;vim&lt;/p&gt;
&lt;p&gt;[2] &amp;nbsp; Killed &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;vim&lt;/p&gt;
&lt;p&gt;Example 3 :&lt;/p&gt;
&lt;p&gt;user du&lt;/p&gt;
&lt;p&gt;# du -sh /opt&lt;/p&gt;
&lt;p&gt; &amp;nbsp;18M &amp;nbsp; /opt&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1081611</link><pubDate>Wed, 15 Nov 2006 20:45:28 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1081611</guid><dc:creator>Example 3</dc:creator><description>&lt;p&gt;Example 3&lt;/p&gt;
&lt;p&gt;For example, if you wanted to calculate the number of bytes in the files in a directory, you would do that with MSH:&lt;/p&gt;
&lt;p&gt;MSH&amp;gt; get-childitem | measure-object -Property length&lt;/p&gt;
&lt;p&gt;Where you just need to call the &amp;quot;du&amp;quot; command in a standard shell:&lt;/p&gt;
&lt;p&gt;SH&amp;gt; du&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1082600</link><pubDate>Thu, 16 Nov 2006 00:36:50 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1082600</guid><dc:creator>Real life examples</dc:creator><description>&lt;p&gt;Is their a method to store the result of a get-childitem (or any other command) who should be reusable in the same way as the original result ?&lt;/p&gt;
&lt;p&gt;With a standard shell this two commands have same result:&lt;/p&gt;
&lt;p&gt;ls|mycommand&lt;/p&gt;
&lt;p&gt;and&lt;/p&gt;
&lt;p&gt;ls &amp;gt; file&lt;/p&gt;
&lt;p&gt;cat file|mycommand&lt;/p&gt;
&lt;p&gt;So you can store the result of a command and resuse it later in the same way. Is it possible with PowerShell ?&lt;/p&gt;
&lt;p&gt;In this case, is the stored data human readable ?&lt;/p&gt;
&lt;p&gt;Do you plan to provide a better terminal emulator than cmd.exe ?&lt;/p&gt;
&lt;p&gt;Should MSH be usable in any other terminal emulator like bash, ksh and others do ?&lt;/p&gt;
&lt;p&gt;I'd like to add an alias on one of my network interfaces with a new IP address, to set a firewall rule that allow access to port 80 on this address, and then to add a VirtualHost on my IIS server with this IP address. How to with MSH ?&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1098219</link><pubDate>Sat, 18 Nov 2006 10:30:50 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1098219</guid><dc:creator>omelet</dc:creator><description>&lt;P&gt;"cmdlet" ? Since when is this suffix back in style ? Don't you have people in your company whose job is to prevent developpers to use lame suffix ?&lt;/P&gt;
&lt;P&gt;Now, excuse-me, but I'm going to take my breakfastlet and then have a showerlet before I go to worklet have my joblet done.&lt;/P&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1102873</link><pubDate>Sun, 19 Nov 2006 13:48:51 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1102873</guid><dc:creator>Antonio</dc:creator><description>&lt;p&gt;Very good job by MS. The power of .NET in the fingers of the Windows Administrators.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1257769</link><pubDate>Mon, 11 Dec 2006 11:44:59 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1257769</guid><dc:creator>Z</dc:creator><description>&lt;p&gt;This article want to treat UNIX as a bad thing willfully. There're much simplier solutions like pkill and du commands instead of using awk and OS dependent parameteres of ps, and such. Also please note that even the whole terminology used by Windows nowdays was created by UNIX, eg the filesystem with directories (the notion of directory, or folder or whatever you want they to be called), device nodes as files, pipes (|), etc. Other stuffs are ripped from CP/M, like device letters (C: ...) FCBs and such. So this powershell stuff is good, but don't treat it as a brand new feature which is the default think in UNIX for dozens of years, also do not try to mystify UNIX CLI that it's overcomplicated when there're simple solutions though they're not in this article ... (even simplier than powershell can provide ...).&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1257839</link><pubDate>Mon, 11 Dec 2006 11:47:22 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1257839</guid><dc:creator>Tester</dc:creator><description>&lt;p&gt;Please send the PowerShell team to a KSH training before creating such examples!&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1257855</link><pubDate>Mon, 11 Dec 2006 11:50:26 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1257855</guid><dc:creator>Z</dc:creator><description>&lt;p&gt;Oh, almost forget: please do not allude to the statement that UNIX has many incomaptible implementations: Windows is much more incomaptible for many standards we have, so it's quite false viewpoint :) Also, you can use much more common and compatible and even simplier solutions like eg pkill than using awk/ps/etc mixed together which - no doubt - requires more knowledge to use of course. Please do not misunderstand me: I don't say powershell and/or Windows are evil. I only say that nobody should say false statements to try to make people think that Windows and its solutions are superior without introduce the GOOD solutions for these problems in UNIX, too.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1277898</link><pubDate>Thu, 14 Dec 2006 00:37:05 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1277898</guid><dc:creator>Ryan</dc:creator><description>&lt;p&gt;Well, considering how MS bashed Unix into the ground, now they are 'reinventing' the Shell...Oooooo...I bet all the Windows admins will be like, &amp;quot;Wow, MS is awesome, look at this sweet command line stuff we can do now! &amp;nbsp;I bet those UNIX guys wish they could do this.&amp;quot;&lt;/p&gt;
&lt;p&gt;History repeats itself...MS just can't get away from UNIX...UNIX is still around today (including Linux) for a good reason!&lt;/p&gt;
&lt;p&gt;UNIX/Linux = Nanometer Legos&lt;/p&gt;
&lt;p&gt;Windows = Duplos&lt;/p&gt;
&lt;p&gt;First they ignore you.&lt;/p&gt;
&lt;p&gt;Then they laugh at you.&lt;/p&gt;
&lt;p&gt;Then they fight you.&lt;/p&gt;
&lt;p&gt;Then you win.&lt;/p&gt;
&lt;p&gt;Ah yes, words of wisdom!&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1280598</link><pubDate>Thu, 14 Dec 2006 08:04:04 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1280598</guid><dc:creator>PowerShellTeam</dc:creator><description>&lt;p&gt;&amp;gt; First they ignore you.&lt;/p&gt;
&lt;p&gt;&amp;gt; Then they laugh at you.&lt;/p&gt;
&lt;p&gt;&amp;gt; Then they fight you.&lt;/p&gt;
&lt;p&gt;&amp;gt; Then you win.&lt;/p&gt;
&lt;p&gt;I can't tell whether you are at the &amp;quot;laughing at us&amp;quot; or the &amp;quot;fighting us&amp;quot; stage. &amp;nbsp;:-)&lt;/p&gt;
&lt;p&gt;Jeffrey Snover [MSFT]&lt;/p&gt;
&lt;p&gt;Windows PowerShell/MMC Architect&lt;/p&gt;
&lt;p&gt;Visit the Windows PowerShell Team blog at: &amp;nbsp; &amp;nbsp;&lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/PowerShell"&gt;http://blogs.msdn.com/PowerShell&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Visit the Windows PowerShell ScriptCenter at: &amp;nbsp;&lt;a rel="nofollow" target="_new" href="http://www.microsoft.com/technet/scriptcenter/hubs/msh.mspx"&gt;http://www.microsoft.com/technet/scriptcenter/hubs/msh.mspx&lt;/a&gt;&lt;/p&gt;
</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1283311</link><pubDate>Thu, 14 Dec 2006 14:52:29 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1283311</guid><dc:creator>Michael Lewis (Thomson Corp)</dc:creator><description>&lt;P&gt;Lets be honest, Powershell uses an excellent new paradigm. &amp;nbsp;It borrows much from unix etc but adds much also. &amp;nbsp;&lt;/P&gt;
&lt;P&gt;However, when doing comparative analysis let's make sure the examples given are reasonable. &amp;nbsp;&lt;/P&gt;
&lt;P&gt;Powershell has much to recommend it, and can hold it's own is a fair comparison. &amp;nbsp;It's case is hindered by not doing a fair comparison. &amp;nbsp;&lt;/P&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1284899</link><pubDate>Thu, 14 Dec 2006 16:53:07 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1284899</guid><dc:creator>PowerShellTeam</dc:creator><description>&lt;p&gt;&amp;gt; Lets be honest, Powershell uses an excellent new paradigm. &amp;nbsp;It borrows much from unix etc but adds much also. &amp;nbsp;&lt;/p&gt;
&lt;p&gt;We have deep respect for Unix. &amp;nbsp;We were cetainly influenced by it but we were also very strongly influenced by VMS and AS400 (those engineers did some superstar work as well). &amp;nbsp;We are able to do what we do because we are standing on the shoulders of giants.&lt;/p&gt;
&lt;p&gt;&amp;gt; It's case is hindered by not doing a fair comparison. &amp;nbsp;&lt;/p&gt;
&lt;p&gt;We believe that it is a fair comparison but, as always, we may be wrong. &amp;nbsp;Please post counterexamples.&lt;/p&gt;
&lt;p&gt;Jeffrey Snover [MSFT]&lt;/p&gt;
&lt;p&gt;Windows PowerShell/MMC Architect&lt;/p&gt;
&lt;p&gt;Visit the Windows PowerShell Team blog at: &amp;nbsp; &amp;nbsp;&lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/PowerShell"&gt;http://blogs.msdn.com/PowerShell&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Visit the Windows PowerShell ScriptCenter at: &amp;nbsp;&lt;a rel="nofollow" target="_new" href="http://www.microsoft.com/technet/scriptcenter/hubs/msh.mspx"&gt;http://www.microsoft.com/technet/scriptcenter/hubs/msh.mspx&lt;/a&gt;&lt;/p&gt;
</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1380467</link><pubDate>Fri, 29 Dec 2006 20:53:31 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1380467</guid><dc:creator>Craig Anderson</dc:creator><description>&lt;p&gt;Is there any &amp;quot;&amp;amp;&amp;quot; (run job in background) equivalent in powershell?&lt;/p&gt;
&lt;p&gt;Example:&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;ping -n 50 10.0.2.1 &amp;gt; /dev/null &amp;amp;&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;ping -n 50 10.0.2.1 &amp;gt; /dev/null &amp;amp;&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;ping -n 50 10.0.2.1 &amp;gt; /dev/null &amp;amp;&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;ping -n 50 10.0.2.1 &amp;gt; /dev/null &amp;amp;&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;wait&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;echo &amp;quot;Pings done&amp;quot;&lt;/p&gt;
&lt;p&gt;Thanks in advance!&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1380737</link><pubDate>Fri, 29 Dec 2006 21:47:05 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1380737</guid><dc:creator>PowerShellTeam</dc:creator><description>&lt;p&gt;&amp;gt; Is there any &amp;quot;&amp;amp;&amp;quot; (run job in background) equivalent in powershell?&lt;/p&gt;
&lt;p&gt;Not in V1 but you can achieve the same semantics using NEW-JOB, a script from Jim Truher: &lt;a rel="nofollow" target="_new" href="http://jtruher.spaces.live.com/blog/cns"&gt;http://jtruher.spaces.live.com/blog/cns&lt;/a&gt;!7143DA6E51A2628D!130.entry&lt;/p&gt;
&lt;p&gt;Jeffrey Snover [MSFT]&lt;/p&gt;
&lt;p&gt;Windows PowerShell/MMC Architect&lt;/p&gt;
&lt;p&gt;Visit the Windows PowerShell Team blog at: &amp;nbsp; &amp;nbsp;&lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/PowerShell"&gt;http://blogs.msdn.com/PowerShell&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Visit the Windows PowerShell ScriptCenter at: &amp;nbsp;&lt;a rel="nofollow" target="_new" href="http://www.microsoft.com/technet/scriptcenter/hubs/msh.mspx"&gt;http://www.microsoft.com/technet/scriptcenter/hubs/msh.mspx&lt;/a&gt;&lt;/p&gt;
</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1748982</link><pubDate>Fri, 23 Feb 2007 22:52:51 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1748982</guid><dc:creator>jj</dc:creator><description>&lt;p&gt;I have programmed in multi os environments for many years (win and unix). While I like some of MS apps (sql server and .net) the winos platform has always been archaic compared to unix for getting work done. I think a true 'shell' language is sooooo over due. I truly hope that Powershell is even close to the power of kshell, bash, etc. However, these days I usually just use Perl to get 'real work done' efficiently, :-). Even has a built-in debugger, primitive, but useful. &amp;nbsp;&lt;/p&gt;
&lt;p&gt;My suggestion before you post comparative examples is that you should have them written by someone that is knowledgeable about the technologies used because whomever wrote these examples clearly are not very skilled, unless of course they were purposely written so that Powershell would look sooo much better. For example, in unix you don't go writing a script when you can just use a built-in command like 'du' and piping the output of awk into grep (excuse me, are you braindead!) awk can very well do that indicating the author was not very awk savvy. &lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1774366</link><pubDate>Wed, 28 Feb 2007 18:04:00 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1774366</guid><dc:creator>Clive Darke</dc:creator><description>&lt;p&gt;Which version of ksh were you comparing against? &amp;nbsp;The latest, ksh93s has some great features, and has far more built-ins than the old ksh88. &amp;nbsp;Likewise, bash has a lot more built-ins than older shells.&lt;/p&gt;
&lt;p&gt;BTW, if you want to annoy a Perl person, call it PERL.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#1867274</link><pubDate>Mon, 12 Mar 2007 23:05:09 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1867274</guid><dc:creator>Nicolas</dc:creator><description>&lt;p&gt;&amp;gt; ps -e | grep &amp;quot; p&amp;quot; | awk '{ print $1 }' | xargs kill&lt;/p&gt;
&lt;p&gt;BTW, most of the time, you don't have to use &amp;quot;grep&amp;quot; when you use &amp;quot;awk&amp;quot;. This command does the same:&lt;/p&gt;
&lt;p&gt;&amp;gt; ps -e | awk '/ p/ { print $1 }' | xargs kill&lt;/p&gt;
&lt;p&gt;That's basic awk ;)&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#2194197</link><pubDate>Thu, 19 Apr 2007 19:59:59 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:2194197</guid><dc:creator>Chuck</dc:creator><description>&lt;p&gt;I was very impressed when reading about PowerShell, until I read this article. &amp;nbsp;I have the same mixed feelings here (great product, sneaky marketing) as I have with other Microsoft tools.&lt;/p&gt;
&lt;p&gt;Still, I will assume that the authors of these comparisons are not very knowledgeable about UNIX system administration, because I'd rather not believe this was a &amp;quot;stacked&amp;quot; comparison.&lt;/p&gt;
&lt;p&gt;What we need is for the proponents of this tool to provide practical comparisons about how to get work done with PowerShell vs. bash, ksh, etc. &amp;nbsp;Even better would have been if Microsoft has come up with a way to integrate the UNIX utilities into their environment so that UNIX system administators would have had an easier time migrating skills, and this should have happened much earlier than it was attempted.&lt;/p&gt;
&lt;p&gt;I can give a specific example of a problem I have encountered with PowerShell. &amp;nbsp;I use the &amp;quot;less&amp;quot; command ported to Windows on my XP box at home. &amp;nbsp;I haven't figured a way to get the &amp;quot;PAGER&amp;quot; environment variable to register with Powershell. &amp;nbsp;Also, I have noticed that Powershell sometimes sends gobbledygook into &amp;quot;Less&amp;quot; when the returned data is large.&lt;/p&gt;
&lt;p&gt;I believe this tool ought to be designed in such a way as to increase the synergy between Windows admins and Unix admins' skills, as tends to be the case between different varieties of UNIX these days. &amp;nbsp;For example, how easy will it be to convert the trillions of Linux or Unix shell scripts, which use many tools not mentioned in the comparisons, to PowerShell scripts? &amp;nbsp;And vise versa?&lt;/p&gt;
&lt;p&gt;All that said, I am inpressed with PowerShell, and hope to see people develop lots of useful scripts to run on it.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#2591423</link><pubDate>Sun, 13 May 2007 08:16:16 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:2591423</guid><dc:creator>Richard Sonnenfeld</dc:creator><description>&lt;p&gt;Chuck was excessively generous. &amp;nbsp;Microsoft is afraid to make Linux/Unix skills transferrable. &amp;nbsp;Microsoft believes Open Source is their enemy. &amp;nbsp;.BAT files used to be not so bad, but they've been continuously dumbed down throuh the years. &amp;nbsp;Obviously some programmers at Microsoft got annoyed by their lame shell and came up with something better. &amp;nbsp;They could have given us ksh or csh like Cygwin, but that would be admitting that Linux has long done what MS long ago lost. &amp;nbsp;So they need to reinvent the wheel in such a way as to try to keep Microsoft skills as distinct as possible from Linux skills. &amp;nbsp;I like free-BSD underneath Max OS X. &amp;nbsp;It's eminently doable by MS, but they are too defensive to do it. &amp;nbsp;Too bad. &amp;nbsp;Prove me wrong guys -- Give me a native korn shell under Windows.&lt;/p&gt;
&lt;p&gt;I'm a professor by the way, and I won't teach my studs. MS skills, because it is in the company's interests to keep changing their tools so you have to keep buying product. &amp;nbsp;This may be fine for professional programmers, but it leaves technical users having to invest way too much time in staying up to date to learn the latest incantation for what they could do 10 and 20 years ago. I tell my students that their Linux chops will last a lifetime. &amp;nbsp;\&lt;/p&gt;
&lt;p&gt;Again -- Prove me wrong guys &lt;/p&gt;</description></item><item><title>Try designing tools for enthusiasts instead of pros</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#2591800</link><pubDate>Sun, 13 May 2007 08:40:15 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:2591800</guid><dc:creator>Richard Sonnenfeld</dc:creator><description>&lt;P&gt;Hi -- I'll be more pleasant now. &amp;nbsp;Reading back all the posts bashing Mr. Snover and the Powershell -- and I see he's taking a lot of flack like a man!&lt;/P&gt;
&lt;P&gt;I stand by my technical comments though, and I'll add context. &amp;nbsp;I've been doing computing for 30 years, on VM/CMS ,CPM ,VAX, DOS, OS2, AIX, Windows and Linux. &amp;nbsp;It has always been from a science/engineering perspective -- programming or shell-scripting to make me more productive at what I was actually being paid to do, rather than developing code or tools for sale. Therefor I cannot afford to become expert in every new tool that comes along, and to the extent that the next tool or shell is something I already know, it is a huge advantage for me. &amp;nbsp;I don't think I am alone. &amp;nbsp;I've noticed my students know less about programming than I did 30 years ago, and I think that all this GUI stuff and constant change has disconnected them from the machine so they cannot engage. &amp;nbsp;&lt;/P&gt;
&lt;P&gt;I don't oppose creative programmers providing us with better tools. &amp;nbsp;I don't suggest using Fortran now that I can use Python. &amp;nbsp;I certainly don't think the kornshell is so great -- it's pretty annoying sometimes, but never underestimate the value of "mindshare". &amp;nbsp;If I already know it, I'll use your version of it. &amp;nbsp;Try to tell the marketing geeks that for us -- will you?&lt;/P&gt;
&lt;P&gt;Good luck -- I'm sure your spirits stay up because you can always compare your salary to that of the posters here!&lt;/P&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#2643906</link><pubDate>Tue, 15 May 2007 10:36:41 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:2643906</guid><dc:creator>somename</dc:creator><description>&lt;p&gt;Looks like the author started his programming straight from power shell without any experience in unix. He seems to have missed&lt;/p&gt;
&lt;p&gt;a whole bunch of commands/utilities in unix &lt;/p&gt;
&lt;p&gt;... pgrep, pkill, df, du, awk ... &lt;/p&gt;
&lt;p&gt;Ya more marketing than good technical comparison. Whenever I read about power shell commands, it looks too suspiciously friendly &lt;/p&gt;
&lt;p&gt;to me. You can do certain things too easy at &lt;/p&gt;
&lt;p&gt;the cost of making certain other things impossible to do.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#2854134</link><pubDate>Fri, 25 May 2007 02:46:31 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:2854134</guid><dc:creator>Nigel Benns</dc:creator><description>&lt;p&gt;Looks like an old article, but I would still like to comment.&lt;/p&gt;
&lt;p&gt;First... your not comparing MSH to the Korn Shell at all, your comparing it to how well the command line utilities are in Unix. &amp;nbsp;The shells in unix are so powerful because of their substitution, piping, multitasking and scripting abilities.&lt;/p&gt;
&lt;p&gt;Can MSH do this:&lt;/p&gt;
&lt;p&gt;#!/bin/ksh&lt;/p&gt;
&lt;p&gt;# loop forever&lt;/p&gt;
&lt;p&gt;while true&lt;/p&gt;
&lt;p&gt;do&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;for file in /path/to/directory/*&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;do&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; export file&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;# run a subprocess&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;(HOST=hostname&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;USER=user&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;PASS=password&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;exec 4&amp;gt;&amp;amp;1&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;ftp -nv &amp;gt;&amp;amp;4 2&amp;gt;&amp;amp;4 |&amp;amp;&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;print -p open $HOST&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;print -p user $USER $PASS&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;print -p cd /remote/directory&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;print -p bin&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;print -p put $file&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;print -p bye&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;wait)&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;done&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;sleep 600 &amp;nbsp;# ten minutes&lt;/p&gt;
&lt;p&gt;done&lt;/p&gt;
&lt;p&gt;I doubt it.&lt;/p&gt;
&lt;p&gt;On the plus side though... I love the .Net runtime. &amp;nbsp;I think its one of the best development environments to come around in a long time.&lt;/p&gt;
&lt;p&gt;Giving a &amp;quot;Unix and Windows&amp;quot; admin an actual shell for windows is a great idea, its like taking a part of home with you on vacation :)&lt;/p&gt;
&lt;p&gt;I am looking forward to actually installing this and being able to telnet/ssh to a windows server and actually accomplish something useful.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#3156870</link><pubDate>Fri, 08 Jun 2007 10:23:39 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:3156870</guid><dc:creator>Rahul Agrawal</dc:creator><description>&lt;p&gt;A new crazy thing from MS. Instead of saying that this is some innovation named Power Shell, I would rather call it that due to increasing price of .NET IDE people can now use a scrapped down version of a crapy language called VBScript from the shell itself.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#3864368</link><pubDate>Sat, 14 Jul 2007 15:38:53 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:3864368</guid><dc:creator>FOO</dc:creator><description>&lt;p&gt;My PowerShell takes nearly 1 second to give me a prompt. Now that is progress! And it ignores %HOME%, why!?&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#4193113</link><pubDate>Thu, 02 Aug 2007 22:55:56 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:4193113</guid><dc:creator>Heiths</dc:creator><description>&lt;p&gt;What I don't understand... Why reinvent the wheel? Why not just incorporate the bash shell into Windows, then add on to that? Honestly, bash is 90% what keeps me using Unix instead of windows. &lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#4439834</link><pubDate>Sat, 18 Aug 2007 04:46:04 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:4439834</guid><dc:creator>Nathan Ramella</dc:creator><description>&lt;p&gt;If you're going to learn a completely new lexicon of tokens that make up the Powershell 'language' .. why not just learn C# and be doing this stuff programatically in an elegant language? &lt;/p&gt;
&lt;p&gt;Powershell looks more like line-noise than line-noise does, and the users you're hoping to placate by transitioning away from VB for incidental scripting are only going to become more sullen about what their options are.&lt;/p&gt;
&lt;p&gt;I won't waste anyone's time comparing apples and oranges with Powershell vs. any existing Windows or Unix shell, really what people should compare it to is C#, since it's an &amp;quot;object oriented scripting language&amp;quot;.. No existing Unix 'shell' has this type of functionality, Unix shells plus interpreted scripting languages like Python or Perl sure, but nothing that really looks like this as a direct interface to OS objects.&lt;/p&gt;
&lt;p&gt;* Getting free disk space using WMI ...&lt;/p&gt;
&lt;p&gt;Get-WmiObject -Class Win32_LogicalDisk -Filter &amp;quot;DriveType=3&amp;quot; -ComputerName . | Measure-Object -Property FreeSpace,Size -Sum&lt;/p&gt;
&lt;p&gt;* &lt;/p&gt;
&lt;p&gt;In C#, this is:&lt;/p&gt;
&lt;p&gt;System.Management.ObjectQuery oQuery = new System.Management.ObjectQuery(&amp;quot;select FreeSpace,Size,Name from Win32_LogicalDisk where DriveType=3&amp;quot;);&lt;/p&gt;
&lt;p&gt;Plus, you get the benefit of object property/method expansion and VS.NET wrapped around it.. &lt;/p&gt;
&lt;p&gt;Seriously guys what were you thinking? The idea of a shell that allows you to pass objects between filters is _great_ but this execution doesn't meet the level of quality that programming C# provides or the level of simplicity that VB provides.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#4846236</link><pubDate>Sun, 09 Sep 2007 21:29:04 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:4846236</guid><dc:creator>PS</dc:creator><description>&lt;p&gt;All I want to do is be able to run a single&lt;/p&gt;
&lt;p&gt;script from a SIGNED file. &amp;nbsp;Why should I have&lt;/p&gt;
&lt;p&gt;to download 354 MB of the .NET SDK in order to&lt;/p&gt;
&lt;p&gt;find a tool that will sign a cmdlet file?&lt;/p&gt;
&lt;p&gt;Why can I not find a download page for&lt;/p&gt;
&lt;p&gt;makecert.exe all by it's flippin self?&lt;/p&gt;
&lt;p&gt;I'm starting to think your powershell is&lt;/p&gt;
&lt;p&gt;a hoax created to make people fear to do &lt;/p&gt;
&lt;p&gt;any scripting at all in Windows.&lt;/p&gt;
&lt;p&gt;Microsoft! hort gut zu: give us a way&lt;/p&gt;
&lt;p&gt;directly ot self-sign a cmdlet without&lt;/p&gt;
&lt;p&gt;downloading reams more MSDN libs or this&lt;/p&gt;
&lt;p&gt;thing ain't usable. &amp;nbsp;Why is it that&lt;/p&gt;
&lt;p&gt;Usability and Microsoft are like &lt;/p&gt;
&lt;p&gt;Oil and Water?&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#5487753</link><pubDate>Wed, 17 Oct 2007 12:20:30 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:5487753</guid><dc:creator>Libor</dc:creator><description>&lt;P&gt;I have read all comments and the majority is a big critisism. The only one think I would appriciate - for .NET familier developers - it would be easier to learn. But why should I use PowerShell when UNIX utilities for Windows works perfect and if I would like to use C# ... then I use C# script NOT PowerShell!&lt;/P&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#5763958</link><pubDate>Mon, 29 Oct 2007 15:51:43 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:5763958</guid><dc:creator>Slash</dc:creator><description>&lt;p&gt;Re: For example, suppose the user wanted to determine which processes were compiled as PreRelease code, such as when applications have been compiled in such a way to mark them as &amp;quot;PreRelease&amp;quot;.&lt;/p&gt;
&lt;p&gt;This is not quite accurate. &amp;nbsp;What you're actually saying is to check whether something compiled by a particular compiler holds symbols. &amp;nbsp;In this case, you're talking about VS. &amp;nbsp;If you use GCC, there are easy ways to check if GCC is holding debug symbols or not. &amp;nbsp;One easy way to do this with GCC is do something like the following:&lt;/p&gt;
&lt;p&gt;echo &amp;quot;quit&amp;quot; | gdb --quiet $EXECNAME | grep -c &amp;quot;no debugging symbols found&amp;quot;&lt;/p&gt;
&lt;p&gt;One line of script to check this.&lt;/p&gt;
&lt;p&gt;If you wanted to add a way to check for a certain build, a common way is to add a static array of characters into the executable that identify this. &amp;nbsp;There are multiple tools that work off of this concept and can easily extract the information. &amp;nbsp;Again, though, generally what you're asking is a feature of the compiler, not the shell. &amp;nbsp;That being said, extracting an array of characters is a technique that could be used across all compilers. &amp;nbsp;It brings back the age old question, why do something the MS-specific way when there's a way that can work in all cases and is easier to understand?&lt;/p&gt;
&lt;p&gt;If the claim is an MS product gives you better access to MS object models, I think we'll all likely agree. &amp;nbsp;However, the honest truth is that it's not useful unless you need MS object models. &amp;nbsp;Even then, what's the advantage of using PowerShell to any of the other .Net scripting languages, which also would give the same access to .Net?&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#6463758</link><pubDate>Thu, 22 Nov 2007 06:40:58 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:6463758</guid><dc:creator>mike</dc:creator><description>&lt;P&gt;what patents have you guys dreamed up for this? I'd like to kill them all with prior art. Seriously, PS looks like a long over-due decent shell Windows, which is great. But you don't fool anybody by pretending this is "innovative". Even the object-oriented idea is not new: &amp;nbsp;look at Plan-9, or BeanShell (which is I think closer to home, being a JVM shell with object hooks into the API... quite like PS's hooks into the CLI API).&lt;/P&gt;
&lt;P&gt;I will play with it, since it stands a much better chance of actually being installed on work's servers (hell will freeze before the mgt let me install cygwin on a production box, paranoid androids...), but it's about as new as everything else from MS (that is, you guys still playing catch-up).&lt;/P&gt;
&lt;P&gt;It feels a lot more like VMS to me, than Unix, btw. Which makes sense, since WNT + 1 = VMS. At least you're starting to admit that the Registry is a hairbrained idea and giving us good access to it via namespaces, so that they appear like files after all! That one's laudable (and laughable).&lt;/P&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#6553342</link><pubDate>Tue, 27 Nov 2007 18:42:24 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:6553342</guid><dc:creator>Matthias Steller</dc:creator><description>&lt;p&gt;I want to use powershell, but when I need hours to find out how I can implement this:&lt;/p&gt;
&lt;p&gt;if exist .\test.txt del .\test.txt &lt;/p&gt;
&lt;p&gt;in PS ... Frustrating.&lt;/p&gt;
&lt;p&gt;Is there comparative examples for the CMD shell ?&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#6632599</link><pubDate>Sat, 01 Dec 2007 20:25:12 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:6632599</guid><dc:creator>Rob H</dc:creator><description>&lt;p&gt;I'm moving from a longtime job using Unix/Linux to an XP world. &amp;nbsp;In my previous incarnation, I leaned heavily on simple ksh or bash jobs made on the fly, maybe a half dozen times/day; these were the core or my productivity. &amp;nbsp;Installing cygwin or even Unix Tools on the machines I work with isn’t an option. &amp;nbsp;I will so miss sed and awk :(&lt;/p&gt;
&lt;p&gt;The big attractions of PS for me are:&lt;/p&gt;
&lt;p&gt;- Runs on the vast array of remote systems infested with a non-POSIX OS, and&lt;/p&gt;
&lt;p&gt;- I can leverage some Unix skills and power using PS aliases&lt;/p&gt;
&lt;p&gt;Primary complaints:The alias list is so incomplete, and those that do exist are only partially equivalent, eg ‘diff’. &amp;nbsp;Underlining this, even the PS examples above can be simplified using supported aliases, e.g. ‘ps y* | kill’.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#6658234</link><pubDate>Wed, 05 Dec 2007 00:51:39 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:6658234</guid><dc:creator>Chuck Bermingham</dc:creator><description>&lt;p&gt;This object-vs-text pipeline is really interesing. &amp;nbsp;But how would I go about mixing properties from 2 different objects accessed in a script to create a third object?&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#6829387</link><pubDate>Fri, 21 Dec 2007 21:37:53 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:6829387</guid><dc:creator>Ross Mohn</dc:creator><description>&lt;p&gt;Back in April, Chuck wanted a way to make &amp;quot;less&amp;quot; his &amp;quot;PAGER&amp;quot;. Since things such as the function &amp;quot;man&amp;quot; explicitly reference the command &amp;quot;more.com&amp;quot;, you need to set 2 aliases to make &amp;quot;less&amp;quot; work everywhere:&lt;/p&gt;
&lt;p&gt;set-alias more less&lt;/p&gt;
&lt;p&gt;set-alias more.com less.exe&lt;/p&gt;
&lt;p&gt;Cheers! -RPM&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#7154332</link><pubDate>Sat, 19 Jan 2008 02:45:30 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:7154332</guid><dc:creator>Sharbat</dc:creator><description>&lt;p&gt;I was wondering if I have a couple of files with tablular info is there an easy way to extract only certain colum(s) and extract only certain rows. And then maybe stich them into one big table assuming number of rows is same in all files.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#7298477</link><pubDate>Tue, 29 Jan 2008 08:01:45 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:7298477</guid><dc:creator>Jerome Gauthier</dc:creator><description>&lt;p&gt;Exceptional Microsoft bad faith at work.. &lt;/p&gt;
&lt;p&gt;Astonishing!&lt;/p&gt;
&lt;p&gt;dot sourcing? &amp;nbsp;WOW! Not THIS is revolutionary...&lt;/p&gt;
&lt;p&gt;Ah but yes, you are right, you didn't mention 'dot sourcing' in this article. Sorry I read too many thing on powershell tonight, I had to vent somewhere and this insult to my intelligence of a comparison article is just that.&lt;/p&gt;
&lt;p&gt;For other readers who might not have had the chance to read elsewhere, YES, you can now call a batch by sourcing it. &amp;quot;. batch.ps1&amp;quot;.&lt;/p&gt;
&lt;p&gt;but beware, it may overwrite variables if done on the command line...&lt;/p&gt;
&lt;p&gt;Guys at MS never understood that sourcing, used in bash and other Linux shells, is used for calling configuration within a script, thus setting variable is the whole point to it... and it wasn't meant to be used on the commandline, like PS is doing. &amp;nbsp;At least get the whole point of a function before implementing it...&lt;/p&gt;
&lt;p&gt;Instead of this outright rip off of conceptual ideas being developed for years, you should have made a call JPSoft way and BUY 4DOS/4NT/TakeCommand which I have been using since DOS v4, when MS brought the oh-so-innovative move.com just another shame when you realize that it should have been in internal command calling (copy) and (delete) as this is truly what this command was doing.&lt;/p&gt;
&lt;p&gt;But enough with history. &amp;nbsp;This is 2008 and you won't fool much people into thinking you are inventing something, much like it has always been done before, mkay?&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#7444827</link><pubDate>Mon, 04 Feb 2008 22:24:03 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:7444827</guid><dc:creator>zev dero</dc:creator><description>&lt;p&gt;It's apples and oranges. &amp;nbsp;I've use dos/wsh/bash/ksh/csh/perl/etc etc. since they were invented. &amp;nbsp;This is mainly an admin language that they tied jscript/vbscript/etc into. &amp;nbsp;I think it rocks. &amp;nbsp;Have you check out the scriptomatic and other helpers? &amp;nbsp;There's a nice GUI out there too.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#7759144</link><pubDate>Mon, 18 Feb 2008 00:24:43 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:7759144</guid><dc:creator>Ramkumar</dc:creator><description>&lt;p&gt;You sense trouble whenever you have people comparing a piece of software which they write with something they probably don't know (or are pretending) the full features of.. A simple example would be of you trying to use ps without the -o pid= option and waxing eloquent about complicated command lines...&lt;/p&gt;
&lt;p&gt;Yes, ps behaves differently on different systems, but well, you just have a single app here.. Allow competitors to write their own &amp;quot;PowerShells&amp;quot; for 10 years, and you will see varied differences in the object models for the process object.. you would $_.WS in one, $_.ws in another, and $_.workingSet in the third, and you are back to the same problem. And well, you have a common denominator for all these commands in unices, called POSIX, and you can expect to get that interface in any compliant UNIX system.&lt;/p&gt;
&lt;p&gt;Having an object model isn't a panacea. You have troubles which you would never perhaps encounter in a text-based flow, like in the shell. You have interfaces, versioning, incompatibility, and on and on... its just that they have one name called formatting differences in text...&lt;/p&gt;
&lt;p&gt;The other flaw seems to be that you seem to be comparing interfaces which are decades old in UNIX with what you have just developed, blissfully ignoring some of the newer shells like zsh which are way more powerful than sh/ksh. You wanted to kill that process starting with p? I do kill p&amp;lt;Tab&amp;gt; and programmatic autocompletion does the rest for me. isn't that better than get-process p* | stop-process? You seem to have ignored the interactive aspect of shells altogether in the comparison. I am not undermining you guys.. you guys have done a good job at this effort, but please don't undermine the presence of such features when putting them under the blanket of 'UNIX shells'.&lt;/p&gt;
&lt;p&gt;Yes, readability is important, but well, everyone has his cup of tea. I am a regular user of UNIX shells, and I have used WSH in the past, its just that many a times, the verbose syntax you potray becomes just painful many a times for some...&lt;/p&gt;
&lt;p&gt;All that you have demonstrated by comparing examples is shown the presence of some of the commands (methods of objects, as you would prefer it) in MSH, which you think are not there in UNIX (But there might be, as an user above has pointed out for du). But the point here is that you are comparing two *shells*, not the utilities which come. It is going to take less than a few minutes for anyone to put in that script and bundle it up as a wait_for_process. You find it easy to package it because you have just one application which understands it, namely PowerShell. POSIX on the other hand has the approach of putting in minimal required functionality as the common denominator, leaving it to the others to build stuff on top of it. And as your target audience, the system administrators, would agree, simpler is surely better!&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#8000951</link><pubDate>Mon, 03 Mar 2008 15:13:14 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8000951</guid><dc:creator>Anonymous</dc:creator><description>&lt;p&gt;Further to others pointing out better ways of doing Example 1:&lt;/p&gt;
&lt;p&gt;The *n*x command as described may actually kill the shell you're running it from!&lt;/p&gt;
&lt;p&gt;Viz., the [incorrect] grep &amp;quot; p&amp;quot; picks up the &amp;quot;pts/0 bash&amp;quot; process.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#8168727</link><pubDate>Wed, 12 Mar 2008 13:56:48 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8168727</guid><dc:creator>Another Anon</dc:creator><description>&lt;p&gt;Well, if you fork example 5 from your shell in bash&lt;/p&gt;
&lt;p&gt;computer:~ user$ sleep 10&amp;amp;&lt;/p&gt;
&lt;p&gt;[1] 3798&lt;/p&gt;
&lt;p&gt;computer:~ user$ wait&lt;/p&gt;
&lt;p&gt;easy!&lt;/p&gt;
&lt;p&gt;RE: Example 4&lt;/p&gt;
&lt;p&gt;this can cause a headache, as your objects can move under your feet.&lt;/p&gt;
&lt;p&gt;Powershell is important for windows as it has never had a decent shell - but why not simply implement a normal POSIX shell, or grab one of the many available shells that are out there. &lt;/p&gt;
&lt;p&gt;You might even be able to fork off some of the Public domain stuff and save a lot of development effort.&lt;/p&gt;
&lt;p&gt;Finally it seems odd that you don't include the manuals to things offline. I do a lot of script writing whilst in transit (trains, aircraft etc) - man has to be one of the more used commands of mine and it saves my bacon many many times. I often need to quickly reference the documentation - what if one is at a site where the router is down and you are trying to PSH &amp;quot;grep&amp;quot; through log files to figure out why - admins don't always have internet access!&lt;/p&gt;
&lt;p&gt;The final question would be how is the programmer to understand the flow of information in constructs such as &amp;quot;get-process p* | stop-process&amp;quot; - I have no idea what is going through that pipe-looking symbol. How does stop-process expect data to come in? Can a write a quick C program to manipulate data in strange ways?&lt;/p&gt;
&lt;p&gt; In sh-style implementations I can be fairly sure that there is only text flowing through, and with a little knowledge about the utilities and the context of my task, I can achieve much - particularly performing tasks for which the shell was never directly intended! This is where the flexability is for me - being able to construct strange and arcane looking commands that do what I want, because I know what each of those symbols mean and exactly how they always behave.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#8352135</link><pubDate>Wed, 02 Apr 2008 21:56:51 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8352135</guid><dc:creator>rob </dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I think the PowerShell is a real improvement over traditional shells.&lt;/p&gt;
&lt;p&gt;I was astonished about the a agressive reactions from the unix ayatollas, allways defending their holy religion and cheating on the ms devel.&lt;/p&gt;
&lt;p&gt;I work as a unix and windows programmer.&lt;/p&gt;
&lt;p&gt;Unix shell programs are a messy patchwork of external programs. &lt;/p&gt;
&lt;p&gt;- the libraries are external programs.&lt;/p&gt;
&lt;p&gt;- there are no compound variables. &lt;/p&gt;
&lt;p&gt;- the results of shell y called by shell x cant be communicated back to x&lt;/p&gt;
&lt;p&gt;- there is no syntax checking, if there is an&lt;/p&gt;
&lt;p&gt;error in some place, it will only show up &lt;/p&gt;
&lt;p&gt;if control goes there.&lt;/p&gt;
&lt;p&gt;- the syntax is terrible: if [ $a ne $b ]&lt;/p&gt;
&lt;p&gt; &amp;nbsp;there must be a spece between [ and $a&lt;/p&gt;
&lt;p&gt;- etc etc&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#8361282</link><pubDate>Sat, 05 Apr 2008 22:21:21 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8361282</guid><dc:creator>rahul</dc:creator><description>&lt;p&gt;Interesting shell. Some questions.&lt;/p&gt;
&lt;p&gt;I would like to know if you have plans to introduce non-linear pipelines (perhaps like CMS pipelines)?&lt;/p&gt;
&lt;p&gt;How do I store the result of a pipe line and reuse it later? &lt;/p&gt;
&lt;p&gt;i.e. How do I do ps -e &amp;gt; a ; cat a | grep $me&lt;/p&gt;
&lt;p&gt;Any chance of getting named pipes ? (May be even pipes with scoped life time unlike that of unix, where the clean up of these pipes are mostly ugly when used as temporary storages.)&lt;/p&gt;
&lt;p&gt;are there things like tee (and fanin and fanout [cms])&lt;/p&gt;
&lt;p&gt;A way to introduce a subshell into a pipeline?&lt;/p&gt;
&lt;p&gt;Dataflow variables like lucid would be a nice addition.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#8672521</link><pubDate>Mon, 30 Jun 2008 22:17:14 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8672521</guid><dc:creator>Chuck</dc:creator><description>&lt;p&gt;Well, I've been in and out of PowerShell since last I posted here, and I have to say it has some potential. &amp;nbsp;To get there, though:&lt;/p&gt;
&lt;p&gt;copy-item should be able to get around MAX_PATH&lt;/p&gt;
&lt;p&gt;Getting a deeply-nested file or directory should be able to get around MAX_PATH&lt;/p&gt;
&lt;p&gt;Speed improvements when reading deeply-nested directories from a server&lt;/p&gt;
&lt;p&gt;Any operation that accesses a directory entry or an ACL should offer the option of preserving the last access date (as LogParser does.)&lt;/p&gt;
&lt;p&gt;Either put support back into LogParser, or make sure PowerShell can offer the same capabilities (including, of course, gathering information about deeply-nested files beyone the reach of MAX_PATH.&lt;/p&gt;
&lt;p&gt;Then maybe we'll talk. &amp;nbsp;I have important system administration work to do that I can perfectly-well do fine on UNIX boxes, and I'm getting tired of jumping through hoops to do the same work on Windows. &amp;nbsp;Powershell is a start.&lt;/p&gt;
&lt;p&gt;Other points:&lt;/p&gt;
&lt;p&gt;How do I get (at least) the same reasonable expectations for a shell on Windows *without* loading the entire .NET framework?&lt;/p&gt;
&lt;p&gt;Well---that's it for now.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#8672596</link><pubDate>Mon, 30 Jun 2008 22:33:05 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8672596</guid><dc:creator>Chuck Bermingham</dc:creator><description>&lt;p&gt;Well, I've been in and out of PowerShell since last I posted here, and I have to say it has some potential. &amp;nbsp;To get there, though:&lt;/p&gt;
&lt;p&gt;copy-item should be able to get around MAX_PATH&lt;/p&gt;
&lt;p&gt;Getting a deeply-nested file or directory should be able to get around MAX_PATH&lt;/p&gt;
&lt;p&gt;Speed improvements when reading deeply-nested directories from a server&lt;/p&gt;
&lt;p&gt;Any operation that accesses a directory entry or an ACL should offer the option of preserving the last access date (as LogParser does.)&lt;/p&gt;
&lt;p&gt;Either put support back into LogParser, or make sure PowerShell can offer the same capabilities (including, of course, gathering information about deeply-nested files beyone the reach of MAX_PATH.&lt;/p&gt;
&lt;p&gt;Then maybe we'll talk. &amp;nbsp;I have important system administration work to do that I can perfectly-well do fine on UNIX boxes, and I'm getting tired of jumping through hoops to do the same work on Windows. &amp;nbsp;Powershell is a start.&lt;/p&gt;
&lt;p&gt;Other points:&lt;/p&gt;
&lt;p&gt;How do I get (at least) the same reasonable expectations for a shell on Windows *without* loading the entire .NET framework?&lt;/p&gt;
&lt;p&gt;Well---that's it for now.&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#8678360</link><pubDate>Tue, 01 Jul 2008 22:32:31 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8678360</guid><dc:creator>Chuck Bermingham</dc:creator><description>&lt;p&gt;Sorry 'bout that! &amp;nbsp;I didn't see the posting and I thought it was because I didn't use my full name the first line. &amp;nbsp;Embarassing! &amp;nbsp;Please delete the extra one (and this one....)&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#9848637</link><pubDate>Sun, 26 Jul 2009 00:35:44 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9848637</guid><dc:creator>Neil Murhphy</dc:creator><description>&lt;p&gt;What does &amp;quot;invariant&amp;quot; mean?&lt;/p&gt;
&lt;p&gt;What does &amp;quot;normalized&amp;quot; mean?&lt;/p&gt;</description></item><item><title>re: Comparative Examples in MSH and KSH</title><link>http://blogs.msdn.com/powershell/archive/2006/04/25/comparative-examples-in-msh-and-ksh.aspx#9931074</link><pubDate>Tue, 01 Dec 2009 21:19:26 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9931074</guid><dc:creator>FireFly</dc:creator><description>&lt;p&gt;Just thought I'd mention what I noticed:&lt;/p&gt;
&lt;p&gt;Example 1: $ killall --regex 'p.*'&lt;/p&gt;
&lt;p&gt;Really, &amp;quot;kill all processes matching regex 'p.*'&amp;quot; is't that hard to read.&lt;/p&gt;
&lt;p&gt;Example 3: $ du -s&lt;/p&gt;
&lt;p&gt;Yeah, the sum of the size of all files in the current folder. &amp;quot;disk usage [of everything in current folder], summarized&amp;quot;&lt;/p&gt;
&lt;p&gt;I didn't understand example 6, I found example 8 perfectly readable and wouldn't call it a flaw.&lt;/p&gt;
&lt;p&gt;Example 9: $ echo &amp;quot;string&amp;quot; | sed 's/./&amp;amp;ABC/'&lt;/p&gt;
&lt;p&gt;Of course, you _could_ make it more obscure than &lt;/p&gt;
&lt;p&gt;necessary, but I'm pretty sure that's possible in MSH too.&lt;/p&gt;
&lt;p&gt;Also, I actually liked the look of PowerShell when I first saw it, and read about how it works... but, now I don't like what I'm seeing, I'll stick to good ol' bash.&lt;/p&gt;
&lt;p&gt;Oh, and if you really need objects, there's always dbus... it uses Qt objects, IIRC.&lt;/p&gt;</description></item></channel></rss>