Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 6 additions & 30 deletions reference/3.0/Microsoft.PowerShell.Core/Functions/Get-Verb.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,40 +84,16 @@ Unprotect Security
This command gets all approved verbs in the Security group.

### Example 4
```
get-command -module MyModule | where { (get-verb $_.Verb) -eq $null }
```powershell
Get-Command -Module Microsoft.PowerShell.Utility | where Verb -NotIn (Get-Verb).Verb
# CommandType Name Version Source
# ----------- ---- ------- ------
# Cmdlet Sort-Object 3.1.0.0 Microsoft.PowerShell.Utility
# Cmdlet Tee-Object 3.1.0.0 Microsoft.PowerShell.Utility
```

Description

-----------

This command finds all commands in a module that have unapproved verbs.

### Example 5
```
$approvedVerbs = get-verb | foreach {$_.verb}

C:\PS> $myVerbs = get-command -module MyModule | foreach {$_.verb}

# Does MyModule export functions with unapproved verbs?
C:\PS> ($myVerbs | foreach {$approvedVerbs -contains $_}) -contains $false
True

# Which unapproved verbs are used in MyModule?
C:\PS> ($myverbs | where {$approvedVerbs -notcontains $_})
ForEach
Sort
Tee
Where
```

Description

-----------

These commands detect unapproved verbs in a module and tell which unapproved verbs were detected in the module.

## PARAMETERS

### -verb
Expand Down
36 changes: 6 additions & 30 deletions reference/4.0/Microsoft.PowerShell.Core/Functions/Get-Verb.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,40 +84,16 @@ Unprotect Security
This command gets all approved verbs in the Security group.

### Example 4
```
get-command -module MyModule | where { (get-verb $_.Verb) -eq $null }
```powershell
Get-Command -Module Microsoft.PowerShell.Utility | where Verb -NotIn (Get-Verb).Verb
# CommandType Name Version Source
# ----------- ---- ------- ------
# Cmdlet Sort-Object 3.1.0.0 Microsoft.PowerShell.Utility
# Cmdlet Tee-Object 3.1.0.0 Microsoft.PowerShell.Utility
```

Description

-----------

This command finds all commands in a module that have unapproved verbs.

### Example 5
```
$approvedVerbs = get-verb | foreach {$_.verb}

C:\PS> $myVerbs = get-command -module MyModule | foreach {$_.verb}

# Does MyModule export functions with unapproved verbs?
C:\PS> ($myVerbs | foreach {$approvedVerbs -contains $_}) -contains $false
True

# Which unapproved verbs are used in MyModule?
C:\PS> ($myverbs | where {$approvedVerbs -notcontains $_})
ForEach
Sort
Tee
Where
```

Description

-----------

These commands detect unapproved verbs in a module and tell which unapproved verbs were detected in the module.

## PARAMETERS

### -verb
Expand Down
36 changes: 6 additions & 30 deletions reference/5.0/Microsoft.PowerShell.Core/Functions/Get-Verb.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,40 +84,16 @@ Unprotect Security
This command gets all approved verbs in the Security group.

### Example 4
```
get-command -module MyModule | where { (get-verb $_.Verb) -eq $null }
```powershell
Get-Command -Module Microsoft.PowerShell.Utility | where Verb -NotIn (Get-Verb).Verb
# CommandType Name Version Source
# ----------- ---- ------- ------
# Cmdlet Sort-Object 3.1.0.0 Microsoft.PowerShell.Utility
# Cmdlet Tee-Object 3.1.0.0 Microsoft.PowerShell.Utility
```

Description

-----------

This command finds all commands in a module that have unapproved verbs.

### Example 5
```
$approvedVerbs = get-verb | foreach {$_.verb}

C:\PS> $myVerbs = get-command -module MyModule | foreach {$_.verb}

# Does MyModule export functions with unapproved verbs?
C:\PS> ($myVerbs | foreach {$approvedVerbs -contains $_}) -contains $false
True

# Which unapproved verbs are used in MyModule?
C:\PS> ($myverbs | where {$approvedVerbs -notcontains $_})
ForEach
Sort
Tee
Where
```

Description

-----------

These commands detect unapproved verbs in a module and tell which unapproved verbs were detected in the module.

## PARAMETERS

### -verb
Expand Down
36 changes: 6 additions & 30 deletions reference/5.1/Microsoft.PowerShell.Core/Functions/Get-Verb.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,40 +84,16 @@ Unprotect Security
This command gets all approved verbs in the Security group.

### Example 4
```
get-command -module MyModule | where { (get-verb $_.Verb) -eq $null }
```powershell
Get-Command -Module Microsoft.PowerShell.Utility | where Verb -NotIn (Get-Verb).Verb
# CommandType Name Version Source
# ----------- ---- ------- ------
# Cmdlet Sort-Object 3.1.0.0 Microsoft.PowerShell.Utility
# Cmdlet Tee-Object 3.1.0.0 Microsoft.PowerShell.Utility
```

Description

-----------

This command finds all commands in a module that have unapproved verbs.

### Example 5
```
$approvedVerbs = get-verb | foreach {$_.verb}

C:\PS> $myVerbs = get-command -module MyModule | foreach {$_.verb}

# Does MyModule export functions with unapproved verbs?
C:\PS> ($myVerbs | foreach {$approvedVerbs -contains $_}) -contains $false
True

# Which unapproved verbs are used in MyModule?
C:\PS> ($myverbs | where {$approvedVerbs -notcontains $_})
ForEach
Sort
Tee
Where
```

Description

-----------

These commands detect unapproved verbs in a module and tell which unapproved verbs were detected in the module.

## PARAMETERS

### -verb
Expand Down
38 changes: 7 additions & 31 deletions reference/6/Microsoft.PowerShell.Utility/Get-Verb.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,41 +80,17 @@ Unprotect up Security Removes safeguards from a resource that wer...

This command gets all approved verbs in the Security group.

### -------------------------- EXAMPLE 4 --------------------------
```
get-command -module MyModule | where { (get-verb $_.Verb) -eq $null }
### Example 4
```powershell
Get-Command -Module Microsoft.PowerShell.Utility | where Verb -NotIn (Get-Verb).Verb
# CommandType Name Version Source
# ----------- ---- ------- ------
# Cmdlet Sort-Object 3.1.0.0 Microsoft.PowerShell.Utility
# Cmdlet Tee-Object 3.1.0.0 Microsoft.PowerShell.Utility
```

Description

-----------

This command finds all commands in a module that have unapproved verbs.

### -------------------------- EXAMPLE 5 --------------------------
```
$approvedVerbs = get-verb | foreach {$_.verb}

C:\PS> $myVerbs = get-command -module MyModule | foreach {$_.verb}

# Does MyModule export functions with unapproved verbs?
C:\PS> ($myVerbs | foreach {$approvedVerbs -contains $_}) -contains $false
True

# Which unapproved verbs are used in MyModule?
C:\PS> ($myverbs | where {$approvedVerbs -notcontains $_})
ForEach
Sort
Tee
Where
```

Description

-----------

These commands detect unapproved verbs in a module and tell which unapproved verbs were detected in the module.

## PARAMETERS

### -verb
Expand Down