- Active Directory
- Internet Explorer
- News About Tome
- Regular Expressions
IT Notes from the Powertoe – Tome Tanasovski
This article continues the last one about architecting a corporate module repository.
I put a formal submission process in place to ensure that all modules meet certain standards. Developers are given a complete set of documentation that outlines best practices that are enforced via a review process. When a developer submits a module for distribution in the repository their module is checked to ensure that it meets the following guidelines:
$sig = @" [DllImport("user32.dll")] public static extern IntPtr GetClipboardData(uint uFormat); [DllImport("user32.dll")] public static extern uint EnumClipboardFormats(uint format); [DllImport("user32.dll")] public static extern bool OpenClipboard(IntPtr hWndNewOwner); [DllImport("user32.dll")] public static extern bool CloseClipboard(); [DllImport("user32.dll")] public static extern bool EmptyClipboard(); [DllImport("user32.dll")] "@ Add-Type -MemberDefinition $sig -Namespace ToeClipboard -Name User32
<# .Notes NAME: AUTHOR: Version: CREATED: 6/17/2010 LASTEDIT: 6/17/2010 1.0 Initial Release .Synopsis One line blurb that discusses cmdlet .Description Multi-line description of cmdlet .Parameter ParameterName1 Description of ParameterName1 .Parameter ParameterName2 Description of ParameterName2 .Inputs Information about the types of input objects accepted .Outputs Information about the objects returned as output from the cmdlet .Example Detailed example. Ideally there should be an example for each set of Parameters and a pipeline example. .Example Additional example .LINK Related cmdlets or relevant URL #>
Are you surprised that I would end this article calling for a Powershell module repository on the Internet? While the infrastructure and design of the in-house module repository I put together for my company will not work on the Internet, I think the standards I outlined for the developer’s guide is something that is enforceable for the module repository we will build on the Internet. In order to be successful we will need a governing body that ensures namespaces and standards are met with new code. I feel that this is the easy part. Just look at all of the Judges for the 2010 Scripting Games; Reading 100 scripts a day that are all nearly identical is hardly anyone’s idea of fun yet there were plenty of community leaders who were happy to take up the task when asked. I think the hard part is the design and maintenance of the infrastructure on the Internet. So get to work people – I guarantee you we can assemble the board to oversee it justly, fairly, and with proper standards in place.
Part three of this series will include my techniques for migrating snapins to modules for both in-house and 3rd party snapins.