Episode 18 – Win Fabulous Prizes!

3 02 2008

A Podcast about Windows PowerShell.


In This Episode
  • Lots of news and tips
  • We missed Jonathan
  • Our first contest–with actual prizes!
  • The PowerShell team blog brings us the news that “PowerShell continues to win awards with Redmond Magazine’s 2008 Editor’s “Slickest Time Saving Tool” co-winner to go along with PS’s Best of Tech-Ed Attendees award and Best of Tech-Ed Client awards.”
  • Kirk Munro covers PowerGUI on DNR.tv .NET Rocks! and RunAsRadio.
  • Karl Prosser (admin frameworks MVP and PowerShell Analyzer architect) was interviewed on the “A Couple of Admins” podcast Episode 35. The interview lasts for almost an hour and I really enjoyed it.
  • Shay@Isreal (The $cript Fanatic blog) put together a cool PowerShell toolbar
  • Admin Frameworks MVP Brandon Shell was interviewed on the CS Techcast podcast. Hal listened to it on the way home the other day and he thought it was a really good interview.
  • VMware’s VI-Toolkit open beta is expected in March
    • Over 70 new cmdlets
    • This example would create a snapshot of every VM:
      get-vm | new-snapshot
  • Dale Lane, author of the IBM Websphere MQ PowerShell snapin is considering writing another tool, this time a PowerShell library for the IBM DB/2 RDBMS.  He is seeking feedback, so if you or someone you know might be interested, please visit this blog post and leave feedback.
  • New Video Podcast: PowerShell-Basics.com
    • This is created by Steve from the A Couple of Admins Podcast.  He wanted to create a screencast-only video podcast.  His first show should be out by the time you hear this.

There’s a ton of Scripting Guys stuff we meant to cover in the interview show last time that we never got around to:

This was used as part of a script Jonathan helped a co-worker with to batch sign ActiveX controls. Thanks to Joel for help on this one.

[Diagnostics.Process]::Start("cmd.exe","/C $robocopycmd")

Hal talks about renaming multiple files which end in an underscore:

$files | %{ Rename-Item -Path $_.FullName -NewName ( $_.Name -replace '_$' ) }

Jonathan talks about grabbing just the first few lines of a huge log file:

get-content *.log -totalCount 5

Hal parried, then riposted with:

get-content | select-object -first 5
PowerScripting / A Couple of Admins Cmdlet Contest

Contest Rules:

  • Three cmdlets announced on each show.
  • Contest entries will be a PowerShell script using all six cmdlets.
  • Entries can be submitted to contest@acoupleofadmins.com
  • Submissions will be taken until February 14th
  • Two winners will be drawn from the entries – one random, one for best script as decided by Steve, Hal, and Jonathan.
  • Prize – commercial license for PowerShell Analyzer (donated by Shell Tools)
  • Prize – commercial license for the NetCmdlets (donated by /n Software)

What are the cmdlets?  You have to listen to find out.  😉

Thanks again to all of you listeners out there!  Your feedback makes it all worthwhile, keep that rolling in.  Our email address is powerscripting@gmail.com, or you can comment on this very blog post.  Also find us on Facebook here (Jonathan), here (Hal),  and here (PowerScripting Podcast group).  Our group needs more members!  The Scripting guys are ahead by a teensy bit.



8 responses

5 02 2008

Listening to your oneliner, I noticed that you used a foreach as rename-item supports scriptblocks as parameters (* Sound like nice topic *hint* )

in your case :

$files | %{ Rename-Item -Path $_.FullName -NewName ( $_.Name -replace ‘_$’ ) }

to :

$files | Rename-Item -Path -NewName {$_.Name -replace ‘_$’ }

I have some more info about this on my old blog here :


Greetings /\/\o\/\/

5 02 2008

Oops also leave out -Path

$files | Ren -New {$_.Name -replace ‘_$’ }

Greetings again

6 02 2008

Thanks as always Mow!

6 02 2008

Hi Fellas ,

Great Podcast . Would you have any more info on auto-it . You were saying how to interact with a Dialog window ? Is this in Bruce’s Book ?


7 02 2008


Glad you mentioned AutoIt. You may have heard Lee Holmes talking about using AutoIt with PowerShell in the latest Powershell Virtual Users Group videos (http://marcoshaw.blogspot.com/2008/02/windows-powershell-virtual-user-group-3.html). He said he’ll be releasing code to the public soon. We’re watching for that, and it will definitely be a topic on a future show, I promise. I was very interested myself in the concept.

Also, SendKeys and AutoIt are mentioned in this newsgroup thread: http://tinyurl.com/2zhp49

21 02 2008

Good show guys.. keep up the good work!

One quick note about [Diagnostics.Process]. You can overload the constructor as you did with two arguments as strings, or you can pass in a StartInfo object, which includes the command, arguments and a bunch of other options as well.

$exe = outlook
$parameter = ‘/safe’
$startinfo = new-object System.Diagnostics.ProcessStartInfo
$startinfo.FileName = $exe
startinfo.Arguments = $parameter
$process = [System.Diagnostics.Process]::Start($startinfo)

Check out the members for StartInfo

You can do things like redirect standard output and standard error. You can also hide the window of the process, so if you wanted to run a cmd command without anything popping up, you can. You can also specify a username and password.

Look for a blog entry on this coming soon 🙂




22 02 2008
Powershell Function Start-Proc « Get-Powershell

[…] Function Start-Proc Posted on February 22, 2008 by Andy The gentlemen over at the Power Scripting Podcast recently posted a tip on how to start processes in […]

26 09 2013

What i do not realize is actually how you are no longer really
much more well-liked than you may be right now. You’re very intelligent.

You understand therefore significantly in the case of
this matter, produced me in my view believe it from numerous various angles.
Its like women and men aren’t involved unless it’s something to do with Lady gaga!
Your own stuffs excellent. All the time deal with it up!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: