Don Jones avatar

Don Jones

Explore articles and content from this author

Don Jones avatar

Don Jones

371 articles  •  5 podcast episodes

2 min read

Event 4 Notes

Loved seeing [OutputType([PSObject])] in an entry this morning… that helps the help system document what your script produces. It’s a shame it doesn’t work well with custom type names (since those are a bit of a fake-out on the object), but it’s an attention to detail I appreciate.
am seeing a little bit of misunderstandings. Keep in mind that the lastLogonTimestamp attribute in AD is the one that replicates, although there is a long possible delay in that replication. There are other “last logged on” attributes that don’t replicate so you can’t rely on them unless you’re querying every DC (pretty inefficient).
Hey, one thing to think about: sometimes simpler is better. For example, instead of adding a dozen lines to check and see if a module exists and can be loaded, just add a #requires comment for that module. Let the shell do that work and spew an error if the module isn’t present. It’ll even force-load the module into memory. Saves lots of steps.
Hey, don’t declare functions as global:Do-This. It’s a neat trick, but you’re polluting the shell’s global scope. Plan to write in-scope functions and make them a script module, so they can be loaded and unloaded. From the Games perspective, “whatever,” but in the real world… don’t pollute the global scope.
A comment I saw: “You should check to make sure the module isn’t loaded before loading it again.” Disagree. The shell does this for you when you use Import-Module. But, doc your module dependency in a #requires, and you won’t have to worry about the module. In fact, the whole theme of “checking to see if the AD module is loaded” appears to be a major point of commenting. I’m a fan of “easier” and a 1-line #requires -module ActiveDirectory is far easier to write and maintain than, say, and entire function designed specifically to load the ActiveDirectory module.

1 min read

Want a premier PowerShell class in your area next year? Help me make it happen.

We’re putting together our schedule for 2014 (yes, already), and we’re looking to hold premier-level PowerShell master classes throughout the world. But… we need your help.
If you’ve got a really top-notch training center in your area that might be interested in working with us, contact me. We’ll need the name of someone there - the training manager, the marketing manager, someone like that. We co-market our classes, but rely on a local center to market to their existing customer base as well. These are premium classes, and they do go for a premium price, so the center has to be comfortable marketing that kind of class. We’re not the run-of-the-mill “official curriculum;” my Master Class packs in around eleven days of “normal” training, covering toolmaking, scripting, and advanced topics as well as the introductory-level stuff. _
_
International contacts are fine, and in fact it’s something I’m excited to get going, as international classes also help me set up future PowerShell Forum and PowerShell Saturday events in a country or region.
So think about your area and see if we might be a fit, and if you’ve got a really top-notch training center you can put us in touch with!

2 min read

Scripting Games Event 3 Winners

We’re pleased to announce the winners for Event 3 of The Scripting Games 2013!
Winners: You can log into The Scripting Games Web site and go to your Profile page to see your prize. You will be given a prize redemption code and either a URL where you can redeem it, or an e-mail address of the prize provider (they will need the redemption code). All prizes must be claimed by the end of July 2013. I will list winners by username; if you used your e-mail address as your username, then a portion of that will be truncated for your privacy. Anyone can log in and check their Profile page to see if they’ve won a prize.
Note: Our hosting company is doing some maintenance on their admin site, so it may be a day or two before redemption codes appear in your Scripting Games profile. Appreciate your patience.
And seriously, you’re killing me with the usernames. Heh.

3 min read

Some Event 3 Notes

I didn’t see anyone (although I’ll admit I haven’t checked every entry) using my EnhancedHTML module from Creating HTML Reports in PowerShell. I am ensaddened.
But man, Event 3 shows that you can really do well by learning a wee bit of HTML. Knowing an H2 and HR tag makes for much pretty results. Take it as career advice.
As a nitpick, don’t use Convert as a function verb unless all the function is going to do is convert something. It shouldn’t “Get” as well. That said, because this event wants a single function that both gets and converts… which is something I’d ordinarily avoid packing into one function… no big. It’s interesting to see the function names folks picked out.
Folks, test your scripts. Seriously.
I kinda giggled when I saw this comment in an entry:

1 min read

Your Weekend Games Report

It’s been a crazy-busy week for me, so I’m just getting caught up here. I’m off observing the beta-teach of the new 10961A PowerShell 3 class in Phoenix next week, but I’ll be keeping an eye on the Games.
So let’s run some numbers.
The Games have 2092 users at present, along with 10960 scores and 5412 comments. There are 849 total entries.
Regarding Event 3, we have 109 Advanced entries and 122 Beginner entries. The average beginner score is 2.8416, and the advanced score is 2.8512. Darn close.
Site traffic is up to 25,000 visits from 18,200 unique visitors, for a total of 56,000 page views and a poo-load of bandwidth. I should have Event 3 winners posted on Tuesday sometime.

1 min read

Meet the Scripting Games Judges: Olver Lipkau

I have been working for AtoS, formaly Siemens IT Solutions and Services, for 6 years as a IT Consultant.
I was 15 when I started scripting. First only batch scripts to automate simple things. With time the scriptt grew in complexity and languages. VBS, AutoIt, AHK and finally PowerShell, which superseeded all others. PowerShell became a passion and became more and more a daily thing.
I was invited to be a judge for the Scripting Games in 2011, 2012 and now 2013.
You are welcome to visit my Blog at http://oliver.lipkau.net/blog and check out what I have been up to.

1 min read

More Updates to the Scripting Games

I’ve been making some more programming changes to the Scripting Games, based on folks’ feedback. If you run into problems, please notify me via the Feedback Forums link at the bottom of every page on the site. Use the email address provided. Don’t post a comment here, because I might not see it quickly.

  • Multiple comments per reviewer - you can now leave multiple comments on an entry. Combined with the ability to mark your comment as pertaining to a line or range of lines, this should allow for more granular commenting.
  • Comment without voting - you are now free to offer comments without offering a score.
  • Delete comments - you can now delete the comments you have written.

I’m still plugging away at some IE9/10-related errors, which are causing the code reviewer/voter/commenter to not display on some entries. In the meantime, Safari, Chrome, and Firefox seem to be working fine.