Charl van Niekerk » Blog

Main

Latest

Archives

Powered by Blogger

Microsoft Windows Power Shell (PoSH)

I didn't think the day would ever come that I would be saying this, but it seems like Microsoft actually invented a decent shell.

Staying in a "small" city like George, the first computers I got to physically interact with were PCs. When I started using PCs back in 1990, the only operating system I used was MS DOS (I can't remember which version, could be 3 or something).

Although at that point in time, my technological standards weren't exactly very high, so I really enjoyed using DOS on a really old computer. The first was a computer (I can't remember which model) with two floppy drives (no hard drive). I think it had a 16-colour (probably 4-bit then) display. Later I moved to a 80286 or something with one floppy drive and one hard drive that was about 8MB or something in size. Ok, it wasn't so old at the time, but it is flipping old now. Later I used Windows 3.1 (which I booted separately from DOS when I felt like it) on a i386 with one floppy and one stiffy drive (no CD/DVD drive - don't be silly). Stiffies were extremely expensive in those days.

Of course later I started using Windows 95 on a Pentium I. I then switched to Windows NT Workstation instead because it's more stable. Windows 98 was so crap I didn't even touch it. When Windows 2000 came I grabbed it and loved it lots. I stuck with it for long before upgrading to Windows XP because the only advantages for me is that it had IPv6 "support" (haha) and booted up much faster. I've been using Linux/BSD "part-time" since the year 2000 but decided to use it "full-time" and chuck Windows out the door roughly a year back. (Tried Solaris 10 but the installation was too slow for me - I think it does well on strong servers with lots of users.)

Had lots of laughs at people using Windows Vista, showing off the visual effects (like it can even be a patch against Linux 3D desktop environments) and then complaining about the various [hard|soft]ware issues they were having, returning back to hacking Linux and giving Vista the finger.

Anyway, how did we get into this nonsense about my crazy life... Back to Windows Shells.

Being used to BASH I spit on DOS. However, I have to say that the new Windows Power Shell (PoSH) does look rather attractive. What I like particularly is that you can do things like this:

"hey i'm tuning you my lanie".ToUpper()

Being used to object orientation as I use it for the gross of the code I write, this is rather attractive to me. This is also rather cool (example taken from the wikipedia page linked to below):

PS> $rssUrl = "http://blogs.msdn.com/powershell/rss.aspx"
PS> $blog = [xml](new-object System.Net.WebClient).DownloadString($rssUrl)
PS> $blog.rss.channel.item | select title -first 8

This displays the latest 8 items of an RSS feed. That's not so bad! Being able to access the .NET framework directly from the shell can be quite handy if you're used to working in that kind of environment.

For those and many more examples, see the Wikipedia PoSH page.

Why Microsoft didn't start with something like this waaaay earlier I have no idea. But if I can access this shell remotely via something like PoSH Remoting I think that this can be quite handy for me when it comes to administrating Windows servers over slow African internet connections when RDP is not an option.

Nothing for the *nix users to be jealous of yet as we have such a range of shells at our disposal we can work out a plan easily to do whatever we like. We have been used to this for a long time, but now the Windows guys can get "with it" as well. It is most certainly a very big step forward for them!

Note to overseas readers: Stiffy is a common computer term, completely socially acceptable in South Africa. It refers to 3½ inch "microfloppy" disks. The term floppy generally refers to 5¼ inch "minifloppy" disks. If you call a 3½ disk a floppy you're likely to get some laughs under the computer people that have been in the business for a while over here. People generally don't even blink at the use of the term "Stiffy" because everybody uses it and expects it. Therefore, keep your dirty thoughts to yourselves and don't bother commenting as I know "stiffy" has, well, interesting meanings in some overseas countries. :P

Check out the Floppy disk Wikipedia article for more info:

In some places, especially South Africa and Zimbabwe, 3½-inch floppy disks have commonly been called stiffies or stiffy disks, because of their "stiff" (rigid) cases, which are contrasted with the flexible "floppy" cases of 5¼-inch floppies. In Finnish, the term is korppu (rusk, crumpet, biscuit) due to its rigidity compared to 5¼-inch lerppu (floppy).

Update: The term PoSH should not be confused with Plain Old Semantic HTML. Another one of the acronyms I love to hate. :)

2 Comments

Comment by Blogger ghost on Thursday, January 24, 2008 12:36:00 PM

http://www.informationweek.com/news/showArticle.jhtml?articleID=205801265&pgno=3&queryText=

2nd paragraph...
you're "the anonymous Unix blog poster"...lol

Comment by Blogger Charl van Niekerk on Thursday, January 24, 2008 3:10:00 PM

Thanks for letting me know! This calls for another blog post. :)

Post a Comment

Copyright © 2004-2009 Charl van Niekerk. All articles are released under the Creative Commons Attribution 2.5 South Africa licence, unless where otherwise stated.