Skip to content

Commit 91c408d

Browse files
authored
Update PowerShell variable provider examples formatting
Reformat code example
1 parent 6c8c805 commit 91c408d

File tree

4 files changed

+24
-16
lines changed

4 files changed

+24
-16
lines changed

reference/5.1/Microsoft.PowerShell.Core/About/about_Variable_Provider.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -159,10 +159,12 @@ This command gets the variables that have the values of `ReadOnly` or
159159
`Constant` for their **Options** property.
160160

161161
```powershell
162-
Get-ChildItem -Path Variable: | Where-Object {
163-
$_.Options -match "Constant" `
164-
-or $_.Options -match "ReadOnly"
165-
} | Format-List -Property Name, Value, Options
162+
Get-ChildItem -Path Variable: |
163+
Where-Object {
164+
$_.Options -match 'Constant' -or
165+
$_.Options -match 'ReadOnly'
166+
} |
167+
Format-List -Property Name, Value, Options
166168
```
167169

168170
## Creating variables

reference/7.4/Microsoft.PowerShell.Core/About/about_Variable_Provider.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -159,10 +159,12 @@ This command gets the variables that have the values of `ReadOnly` or
159159
`Constant` for their **Options** property.
160160

161161
```powershell
162-
Get-ChildItem -Path Variable: | Where-Object {
163-
$_.Options -match "Constant" `
164-
-or $_.Options -match "ReadOnly"
165-
} | Format-List -Property Name, Value, Options
162+
Get-ChildItem -Path Variable: |
163+
Where-Object {
164+
$_.Options -match 'Constant' -or
165+
$_.Options -match 'ReadOnly'
166+
} |
167+
Format-List -Property Name, Value, Options
166168
```
167169

168170
## Creating variables

reference/7.5/Microsoft.PowerShell.Core/About/about_Variable_Provider.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -159,10 +159,12 @@ This command gets the variables that have the values of `ReadOnly` or
159159
`Constant` for their **Options** property.
160160

161161
```powershell
162-
Get-ChildItem -Path Variable: | Where-Object {
163-
$_.Options -match "Constant" `
164-
-or $_.Options -match "ReadOnly"
165-
} | Format-List -Property Name, Value, Options
162+
Get-ChildItem -Path Variable: |
163+
Where-Object {
164+
$_.Options -match 'Constant' -or
165+
$_.Options -match 'ReadOnly'
166+
} |
167+
Format-List -Property Name, Value, Options
166168
```
167169

168170
## Creating variables

reference/7.6/Microsoft.PowerShell.Core/About/about_Variable_Provider.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -159,10 +159,12 @@ This command gets the variables that have the values of `ReadOnly` or
159159
`Constant` for their **Options** property.
160160

161161
```powershell
162-
Get-ChildItem -Path Variable: | Where-Object {
163-
$_.Options -match "Constant" `
164-
-or $_.Options -match "ReadOnly"
165-
} | Format-List -Property Name, Value, Options
162+
Get-ChildItem -Path Variable: |
163+
Where-Object {
164+
$_.Options -match 'Constant' -or
165+
$_.Options -match 'ReadOnly'
166+
} |
167+
Format-List -Property Name, Value, Options
166168
```
167169

168170
## Creating variables

0 commit comments

Comments
 (0)