Last active
July 1, 2020 17:08
-
-
Save tekkies/39688d3122f6f0edc8d75061083efd32 to your computer and use it in GitHub Desktop.
Template PowerShell script with help and params
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# | |
.SYNOPSIS | |
10 words | |
.DESCRIPTION | |
Tweet | |
.NOTES | |
Full description | |
On multiple lines | |
.PARAMETER Mandatory | |
This ian a mandatory param | |
.PARAMETER Optional | |
This is an optional param | |
.PARAMETER Help | |
Show this help. | |
.EXAMPLE | |
Template.ps1 -Mandatory mandatoryValue -Optional optionalValue | |
#> | |
param([Parameter(Mandatory=$true)][string]$Mandatory, [string]$Optional="optionalValue",[switch]$Help) | |
$ErrorActionPreference = "Stop" | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment