You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
"Examples": "\r\n-------------------------- EXAMPLE 1 --------------------------\r\n\r\nPS C:\\\u003eRemove-DbaAgentJob -SqlInstance sql1 -Job Job1\r\n\r\nRemoves the job from the instance with the name Job1\r\n\r\n\r\n\r\n\r\n-------------------------- EXAMPLE 2 --------------------------\r\n\r\nPS C:\\\u003eRemove-DbaAgentJob -SqlInstance sql1 -Job Job1 -KeepHistory\r\n\r\nRemoves the job but keeps the history\r\n\r\n\r\n\r\n\r\n-------------------------- EXAMPLE 3 --------------------------\r\n\r\nPS C:\\\u003eRemove-DbaAgentJob -SqlInstance sql1 -Job Job1 -KeepUnusedSchedule\r\n\r\nRemoves the job but keeps the unused schedules\r\n\r\n\r\n\r\n\r\n-------------------------- EXAMPLE 4 --------------------------\r\n\r\nPS C:\\\u003eRemove-DbaAgentJob -SqlInstance sql1, sql2, sql3 -Job Job1\r\n\r\nRemoves the job from multiple servers\r\n\r\n\r\n\r\n\r\n-------------------------- EXAMPLE 5 --------------------------\r\n\r\nPS C:\\\u003esql1, sql2, sql3 | Remove-DbaAgentJob -Job Job1\r\n\r\nRemoves the job from multiple servers using pipe line\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n"
3538
+
"Examples": "\r\n-------------------------- EXAMPLE 1 --------------------------\r\n\r\nPS C:\\\u003eRemove-DbaAgentJob -SqlInstance sql1 -Job Job1\r\n\r\nRemoves the job from the instance with the name Job1\r\n\r\n\r\n\r\n\r\n-------------------------- EXAMPLE 2 --------------------------\r\n\r\nPS C:\\\u003eGetDbaAgentJob -SqlInstance sql1 -Job Job1 | Remove-DbaAgentJob -KeepHistory\r\n\r\n\r\n\r\n\r\n\r\n\r\n-------------------------- EXAMPLE 3 --------------------------\r\n\r\nPS C:\\\u003eRemove-DbaAgentJob -SqlInstance sql1 -Job Job1 -KeepUnusedSchedule\r\n\r\nRemoves the job but keeps the unused schedules\r\n\r\n\r\n\r\n\r\n-------------------------- EXAMPLE 4 --------------------------\r\n\r\nPS C:\\\u003eRemove-DbaAgentJob -SqlInstance sql1, sql2, sql3 -Job Job1\r\n\r\nRemoves the job from multiple servers\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n"
Copy file name to clipboardExpand all lines: functions/Install-DbaFirstResponderKit.ps1
+78-36Lines changed: 78 additions & 36 deletions
Original file line number
Diff line number
Diff line change
@@ -24,6 +24,13 @@ function Install-DbaFirstResponderKit {
24
24
.PARAMETERBranch
25
25
Specifies an alternate branch of the First Responder Kit to install. (master or dev)
26
26
27
+
.PARAMETERLocalFile
28
+
Specifies the path to a local file to install FRK from. This *should* be the zipfile as distributed by the maintainers.
29
+
If this parameter is not specified, the latest version will be downloaded and installed from https://github.com/BrentOzarULTD/SQL-Server-First-Responder-Kit
30
+
31
+
.PARAMETERForce
32
+
If this switch is enabled, the FRK will be downloaded from the internet even if previously cached.
33
+
27
34
.PARAMETERConfirm
28
35
Prompts to confirm actions
29
36
@@ -85,57 +92,90 @@ function Install-DbaFirstResponderKit {
Stop-Function-Message "Couldn't download the First Responder Kit. Download and install manually from https://github.com/BrentOzarULTD/SQL-Server-First-Responder-Kit/archive/$Branch.zip."-ErrorRecord $_
Stop-Function-Message "Couldn't download the First Responder Kit. Download and install manually from https://github.com/BrentOzarULTD/SQL-Server-First-Responder-Kit/archive/$Branch.zip."-ErrorRecord $_
163
+
return
164
+
}
165
+
}
166
+
167
+
## Copy it into local area
168
+
if (Test-Path-Path $LocalCachedCopy-PathType Container) {
0 commit comments