What are Toolkit Extensions?

//What are Toolkit Extensions?
What are Toolkit Extensions?2015-08-28T02:32:16+00:00

The Toolkit Forums Toolkit Extensions What are Toolkit Extensions?

  • Author
  • Muhammad Mashwani
    Post count: 118

    One of the key goals of the PowerShell App Deployment Toolkit is to provide a consistent set of core functions that can be reused when deploying applications. It’s very likely however, that you will have additional functions that you would like to reuse. It’s easy to create your own functions and extend the toolkit without any modification to the core toolkit itself – which makes updating to new versions quick and painless.

    To add an extension to the toolkit, add the function to the body of PSAppDepoyToolkitExtensions.ps1.

    Please post properly formatted code to the discussion forums by either using the “crayon” button in the editor or surrounding your code with the pre tag.

    To help you get started, we have included a template for creating a function in the same style as those included in the toolkit:

    ## Microsoft Function Naming Convention: http://msdn.microsoft.com/en-us/library/ms714428(v=vs.85).aspx
    Function Verb-Noun {
    	Param (
    	Begin {
    		## Get the name of this function and write header
    		[string]${CmdletName} = $PSCmdlet.MyInvocation.MyCommand.Name
    		Write-FunctionHeaderOrFooter -CmdletName ${CmdletName} -CmdletBoundParameters $PSBoundParameters -Header
    	Process {
    		Try {
    		Catch {
    			Write-Log -Message "<error message>. `n$(Resolve-Error)" -Severity 3 -Source ${CmdletName}
    	End {
    		Write-FunctionHeaderOrFooter -CmdletName ${CmdletName} -Footer
  • Sue
    Post count: 4

    Hi there.

    I had a couple of functions that worked in the older version of the toolkit – 3.2.0, and they used to show in the help file. I have copied these into the new version, 3.6.4, extensions script and I no longer see them in the help file. Has something changed? I have followed the above, but they don’t seem to appear.


  • Sue
    Post count: 4

    Update – I have just replaced the 3.6.4 extensions script with the one I customised for 3.2.0 and it is all working again. I don’t see anything in particular that would affect the extensions script, but maybe I am missing something.

You must be logged in to reply to this topic.