< Back
Find-DbaCommand
Post
NAME Find-DbaCommand
SYNOPSIS
Finds dbatools commands searching through the inline help text
SYNTAX
Find-DbaCommand [[-Pattern] <String>] [[-Tag] <System.String[]>] [[-Author] <String>] [[-MinimumVersion] <String>]
[[-MaximumVersion] <String>] [-Rebuild <Switch>] [-EnableException <Switch>] [<CommonParameters>]
DESCRIPTION
Finds dbatools commands searching through the inline help text, building a consolidated json index and querying it
because Get-Help is too slow
PARAMETERS
-Author [<String>]
Finds all commands tagged with this author
Required? false
Position? named
Default value
Accept pipeline input? False
Accept wildcard characters? false
-EnableException [<Switch>]
By default, when something goes wrong we try to catch it, interpret it and give you a friendly warning message.
This avoids overwhelming you with "sea of red" exceptions, but is inconvenient because it basically disables
advanced scripting.
Using this switch turns this "nice by default" feature off and enables you to catch exceptions with your own
try/catch.
Required? false
Position? named
Default value
Accept pipeline input? False
Accept wildcard characters? false
-MaximumVersion [<String>]
Finds all commands tagged with this auto-populated maximum version
Required? false
Position? named
Default value
Accept pipeline input? False
Accept wildcard characters? false
-MinimumVersion [<String>]
Finds all commands tagged with this auto-populated minimum version
Required? false
Position? named
Default value
Accept pipeline input? False
Accept wildcard characters? false
-Pattern [<String>]
Searches help for all commands in dbatools for the specified pattern and displays all results
Required? false
Position? named
Default value
Accept pipeline input? False
Accept wildcard characters? false
-Rebuild [<Switch>]
Rebuilds the index
Required? false
Position? named
Default value
Accept pipeline input? False
Accept wildcard characters? false
-Tag [<System.String[]>]
Finds all commands tagged with this auto-populated tag
Required? false
Position? named
Default value
Accept pipeline input? False
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
NOTES
Tags: Module, Find
Author: Simone Bizzotto (@niphlod)
Website: https://dbatools.io
Copyright: (c) 2018 by dbatools, licensed under MIT
License: MIT https://opensource.org/licenses/MIT
-------------------------- EXAMPLE 1 --------------------------
PS C:\\>Find-DbaCommand "snapshot"
For lazy typers: finds all commands searching the entire help for "snapshot"
-------------------------- EXAMPLE 2 --------------------------
PS C:\\>Find-DbaCommand -Pattern "snapshot"
For rigorous typers: finds all commands searching the entire help for "snapshot"
-------------------------- EXAMPLE 3 --------------------------
PS C:\\>Find-DbaCommand -Tag Job
Finds all commands tagged with "Job"
-------------------------- EXAMPLE 4 --------------------------
PS C:\\>Find-DbaCommand -Tag Job,Owner
Finds all commands tagged with BOTH "Job" and "Owner"
-------------------------- EXAMPLE 5 --------------------------
PS C:\\>Find-DbaCommand -Author Chrissy
Finds every command whose author contains our beloved "Chrissy"
-------------------------- EXAMPLE 6 --------------------------
PS C:\\>Find-DbaCommand -Author Chrissy -Tag AG
Finds every command whose author contains our beloved "Chrissy" and it tagged as "AG"
-------------------------- EXAMPLE 7 --------------------------
PS C:\\>Find-DbaCommand -Pattern snapshot -Rebuild
Finds all commands searching the entire help for "snapshot", rebuilding the index (good for developers)
RELATED LINKS
https://dbatools.io/Find-DbaCommand
SYNOPSIS
Finds dbatools commands searching through the inline help text
SYNTAX
Find-DbaCommand [[-Pattern] <String>] [[-Tag] <System.String[]>] [[-Author] <String>] [[-MinimumVersion] <String>]
[[-MaximumVersion] <String>] [-Rebuild <Switch>] [-EnableException <Switch>] [<CommonParameters>]
DESCRIPTION
Finds dbatools commands searching through the inline help text, building a consolidated json index and querying it
because Get-Help is too slow
PARAMETERS
-Author [<String>]
Finds all commands tagged with this author
Required? false
Position? named
Default value
Accept pipeline input? False
Accept wildcard characters? false
-EnableException [<Switch>]
By default, when something goes wrong we try to catch it, interpret it and give you a friendly warning message.
This avoids overwhelming you with "sea of red" exceptions, but is inconvenient because it basically disables
advanced scripting.
Using this switch turns this "nice by default" feature off and enables you to catch exceptions with your own
try/catch.
Required? false
Position? named
Default value
Accept pipeline input? False
Accept wildcard characters? false
-MaximumVersion [<String>]
Finds all commands tagged with this auto-populated maximum version
Required? false
Position? named
Default value
Accept pipeline input? False
Accept wildcard characters? false
-MinimumVersion [<String>]
Finds all commands tagged with this auto-populated minimum version
Required? false
Position? named
Default value
Accept pipeline input? False
Accept wildcard characters? false
-Pattern [<String>]
Searches help for all commands in dbatools for the specified pattern and displays all results
Required? false
Position? named
Default value
Accept pipeline input? False
Accept wildcard characters? false
-Rebuild [<Switch>]
Rebuilds the index
Required? false
Position? named
Default value
Accept pipeline input? False
Accept wildcard characters? false
-Tag [<System.String[]>]
Finds all commands tagged with this auto-populated tag
Required? false
Position? named
Default value
Accept pipeline input? False
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
OUTPUTS
NOTES
Tags: Module, Find
Author: Simone Bizzotto (@niphlod)
Website: https://dbatools.io
Copyright: (c) 2018 by dbatools, licensed under MIT
License: MIT https://opensource.org/licenses/MIT
-------------------------- EXAMPLE 1 --------------------------
PS C:\\>Find-DbaCommand "snapshot"
For lazy typers: finds all commands searching the entire help for "snapshot"
-------------------------- EXAMPLE 2 --------------------------
PS C:\\>Find-DbaCommand -Pattern "snapshot"
For rigorous typers: finds all commands searching the entire help for "snapshot"
-------------------------- EXAMPLE 3 --------------------------
PS C:\\>Find-DbaCommand -Tag Job
Finds all commands tagged with "Job"
-------------------------- EXAMPLE 4 --------------------------
PS C:\\>Find-DbaCommand -Tag Job,Owner
Finds all commands tagged with BOTH "Job" and "Owner"
-------------------------- EXAMPLE 5 --------------------------
PS C:\\>Find-DbaCommand -Author Chrissy
Finds every command whose author contains our beloved "Chrissy"
-------------------------- EXAMPLE 6 --------------------------
PS C:\\>Find-DbaCommand -Author Chrissy -Tag AG
Finds every command whose author contains our beloved "Chrissy" and it tagged as "AG"
-------------------------- EXAMPLE 7 --------------------------
PS C:\\>Find-DbaCommand -Pattern snapshot -Rebuild
Finds all commands searching the entire help for "snapshot", rebuilding the index (good for developers)
RELATED LINKS
https://dbatools.io/Find-DbaCommand