Skip to content

Commit aad2338

Browse files
Fix automatic variable case (#11838)
1 parent 744ca8e commit aad2338

26 files changed

+69
-69
lines changed

reference/docs-conceptual/developer/cmdlet/extending-output-objects.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ title: Extending Output Objects
66
---
77
# Extending Output Objects
88

9-
You can extend the .NET Framework objects that are returned by cmdlets, functions, and scripts by using types files (.ps1xml). Types files are XML-based files that let you add properties and methods to existing objects. For example, Windows PowerShell provides the Types.ps1xml file, which adds elements to several existing .NET Framework objects. The Types.ps1xml file is located in the Windows PowerShell installation directory (`$pshome`). You can create your own types file to further extend those objects or to extend other objects. When you extend an object by using a types file, any instance of the object is extended with the new elements.
9+
You can extend the .NET Framework objects that are returned by cmdlets, functions, and scripts by using types files (.ps1xml). Types files are XML-based files that let you add properties and methods to existing objects. For example, Windows PowerShell provides the Types.ps1xml file, which adds elements to several existing .NET Framework objects. The Types.ps1xml file is located in the Windows PowerShell installation directory (`$PSHOME`). You can create your own types file to further extend those objects or to extend other objects. When you extend an object by using a types file, any instance of the object is extended with the new elements.
1010

1111
## Extending the System.Array Object
1212

@@ -66,7 +66,7 @@ PS> (1, 2, 3, 4).Length
6666

6767
## Custom Types Files
6868

69-
To create a custom types file, start by copying an existing types file. The new file can have any name, but it must have a .ps1xml file name extension. When you copy the file, you can place the new file in any directory that is accessible to Windows PowerShell, but it is useful to place the files in the Windows PowerShell installation directory (`$pshome`) or in a subdirectory of the installation directory.
69+
To create a custom types file, start by copying an existing types file. The new file can have any name, but it must have a .ps1xml file name extension. When you copy the file, you can place the new file in any directory that is accessible to Windows PowerShell, but it is useful to place the files in the Windows PowerShell installation directory (`$PSHOME`) or in a subdirectory of the installation directory.
7070

7171
To add your own extended types to the file, add a types element for each object that you want to extend. The following topics provide examples.
7272

reference/docs-conceptual/developer/format/powershell-formatting-files.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ title: Windows PowerShell Formatting Files
77
# Windows PowerShell Formatting Files
88

99
Windows PowerShell provides several formatting files (.format.ps1xml) that are located in the
10-
installation directory (`$pshome`). Each of these files defines the default display for a specific
10+
installation directory (`$PSHOME`). Each of these files defines the default display for a specific
1111
set of .NET objects. These files should never be changed. However, you can use them as a reference
1212
for creating your own custom formatting files.
1313

reference/docs-conceptual/developer/hosting/host04-sample.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ This sample requires Windows PowerShell 2.0.
2727
- Building a console application that uses these host classes to build an interactive Windows
2828
PowerShell shell.
2929

30-
- Creating a `$profile` variable and loading the following profiles.
30+
- Creating a `$PROFILE` variable and loading the following profiles.
3131

3232
- current user, current host
3333
- current user, all hosts
@@ -145,7 +145,7 @@ namespace Microsoft.Samples.PowerShell.Host
145145
this.myRunSpace.Open();
146146

147147
// Create a PowerShell object that will be used to execute the commands
148-
// to create $profile and load the profiles.
148+
// to create $PROFILE and load the profiles.
149149
lock (this.instanceLock)
150150
{
151151
this.currentPowerShell = PowerShell.Create();

reference/docs-conceptual/developer/hosting/host05-sample.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ host application also supports calls to remote computers by using the
3030

3131
- Building a console application that uses these host classes to build an interactive Windows PowerShell shell.
3232

33-
- Creating a `$profile` variable and loading the following profiles.
33+
- Creating a `$PROFILE` variable and loading the following profiles.
3434

3535
- current user, current host
3636
- current user, all hosts
@@ -159,7 +159,7 @@ namespace Microsoft.Samples.PowerShell.Host
159159
this.myRunSpace.Open();
160160

161161
// Create a PowerShell object to run the commands used to create
162-
// $profile and load the profiles.
162+
// $PROFILE and load the profiles.
163163
lock (this.instanceLock)
164164
{
165165
this.currentPowerShell = PowerShell.Create();

reference/docs-conceptual/developer/hosting/host06-sample.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ the user.
2929
- Building a console application that uses these host classes to build an interactive Windows
3030
PowerShell shell.
3131

32-
- Creating a `$profile` variable and loading the following profiles.
32+
- Creating a `$PROFILE` variable and loading the following profiles.
3333

3434
- current user, current host
3535
- current user, all hosts
@@ -165,7 +165,7 @@ namespace Microsoft.Samples.PowerShell.Host
165165
this.myRunSpace.Open();
166166

167167
// Create a PowerShell object to run the commands used to create
168-
// $profile and load the profiles.
168+
// $PROFILE and load the profiles.
169169
lock (this.instanceLock)
170170
{
171171
this.currentPowerShell = PowerShell.Create();

reference/docs-conceptual/developer/module/how-to-write-a-powershell-module-manifest.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ The following table describes the elements you can include in a module manifest.
9393
| **Copyright**<br /> Type: `String` | `'(c) <Author>. All rights reserved.'` | Copyright statement for this module. If a value isn't specified, `New-ModuleManifest` uses the default with the current user as the `<Author>`. To specify an author, use the **Author** parameter. <br /> Example: `Copyright = '2019 AuthorName. All rights reserved.'` |
9494
| **Description**<br /> Type: `String` | `<empty string>` | Description of the functionality provided by this module.<br /> Example: `Description = 'This is the module's description.'` |
9595
| **PowerShellVersion**<br /> Type: `Version` | `<empty string>` | Minimum version of the PowerShell engine required by this module. Valid values are 1.0, 2.0, 3.0, 4.0, 5.0, 5.1, 6.0, 6.1, 6.2, 7.0 and 7.1.<br /> Example: `PowerShellVersion = '5.0'` |
96-
| **PowerShellHostName**<br /> Type: `String` | `<empty string>` | Name of the PowerShell host required by this module. This name is provided by PowerShell. To find the name of a host program, in the program, type: `$host.name`.<br /> Example: `PowerShellHostName = 'ConsoleHost'` |
96+
| **PowerShellHostName**<br /> Type: `String` | `<empty string>` | Name of the PowerShell host required by this module. This name is provided by PowerShell. To find the name of a host program, in the program, type: `$Host.name`.<br /> Example: `PowerShellHostName = 'ConsoleHost'` |
9797
| **PowerShellHostVersion**<br /> Type: `Version` | `<empty string>` | Minimum version of the PowerShell host required by this module.<br /> Example: `PowerShellHostVersion = '2.0'` |
9898
| **DotNetFrameworkVersion**<br /> Type: `Version` | `<empty string>` | Minimum version of Microsoft .NET Framework required by this module. This prerequisite is valid for the PowerShell Desktop edition only, such as Windows PowerShell 5.1, and only applies to .NET Framework versions lower than 4.5. <br /> Example: `DotNetFrameworkVersion = '3.5'` |
9999
| **CLRVersion**<br /> Type: `Version` | `<empty string>` | Minimum version of the common language runtime (CLR) required by this module. This prerequisite is valid for the PowerShell Desktop edition only, such as Windows PowerShell 5.1, and only applies to .NET Framework versions lower than 4.5. <br /> Example: `CLRVersion = '3.5'` |

reference/docs-conceptual/developer/module/installing-a-powershell-module.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ PowerShell modules. Cmdlets rely on the value of this environment variable to fi
3333
By default, the **PSModulePath** environment variable value contains the following system and user
3434
module directories, but you can add to and edit the value.
3535

36-
- `$PSHome\Modules` (`%Windir%\System32\WindowsPowerShell\v1.0\Modules`)
36+
- `$PSHOME\Modules` (`%Windir%\System32\WindowsPowerShell\v1.0\Modules`)
3737

3838
> [!WARNING]
3939
> This location is reserved for modules that ship with Windows. Do not install modules to this

reference/docs-conceptual/how-to-use-docs.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ If there are version-specific differences, the documentation makes note of those
4848

4949
![Animation showing how to use the version selector.][04]
5050

51-
You can verify the version of PowerShell you are using by inspecting the `$PSversionTable.PSVersion`
51+
You can verify the version of PowerShell you are using by inspecting the `$PSVersionTable.PSVersion`
5252
value. The following example shows the output for Windows PowerShell 5.1.
5353

5454
```powershell

reference/docs-conceptual/lang-spec/chapter-04.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -929,7 +929,7 @@ In PowerShell, this type is `System.Management.Automation.PSCustomObject`. The c
929929

930930
### 4.5.14 Command description type
931931

932-
The automatic variable `$PsCmdlet` is an object that represents the cmdlet or function being
932+
The automatic variable `$PSCmdlet` is an object that represents the cmdlet or function being
933933
executed. The type of this object is implementation defined; it has the following accessible
934934
members:
935935

reference/docs-conceptual/lang-spec/chapter-07.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1698,10 +1698,10 @@ dash:
16981698
Description:
16991699

17001700
If the left operand does not designate a collection, the result has type `bool` and if that result
1701-
is `$true`, the elements of the Hashtable `$matches` are set to the strings that match (or
1701+
is `$true`, the elements of the Hashtable `$Matches` are set to the strings that match (or
17021702
do-not-match) the value designated by the right operand. Otherwise, the result is a possibly empty
17031703
unconstrained 1-dimensional array containing the elements of the collection that test True when
1704-
compared to the value designated by the right operand, and `$matches` is not set. The right operand
1704+
compared to the value designated by the right operand, and `$Matches` is not set. The right operand
17051705
may designate a string that contains regular expressions ([§3.16][§3.16]), in which case, it is
17061706
referred to as a _pattern_. These operators have two variants ([§7.8][§7.8]).
17071707

@@ -1710,11 +1710,11 @@ These operators support submatches ([§7.8.4.6][§7.8.4.6]).
17101710
Examples:
17111711

17121712
```powershell
1713-
"Hello" -match ".l" # True, $matches key/value is 0/"el"
1714-
"Hello" -match '\^h.*o$' # True, $matches key/value is
1713+
"Hello" -match ".l" # True, $Matches key/value is 0/"el"
1714+
"Hello" -match '\^h.*o$' # True, $Matches key/value is
17151715
0/"Hello"
1716-
"Hello" -cmatch '\^h.*o$' # False, $matches not set
1717-
"abc\^ef" -match ".\\\^e" # True, $matches key/value is 0/"c\^e"
1716+
"Hello" -cmatch '\^h.*o$' # False, $Matches not set
1717+
"abc\^ef" -match ".\\\^e" # True, $Matches key/value is 0/"c\^e"
17181718
17191719
"abc" -notmatch "[A-Za-z]" # False
17201720
"abc" -match "[\^A-Za-z]" # False
@@ -1885,7 +1885,7 @@ _submatches_) delimited by parentheses. Consider the following example:
18851885

18861886
`"red" -match "red"`
18871887

1888-
The result is `$true` and key 0 of `$matches` contains "red", that part of the string designated by
1888+
The result is `$true` and key 0 of `$Matches` contains "red", that part of the string designated by
18891889
the left operand that exactly matched the pattern designated by the right operand.
18901890

18911891
In the following example, the whole pattern is a submatch:
@@ -1914,7 +1914,7 @@ In the case of `-replace`, the replacement text can access the submatches via na
19141914

19151915
The resulting string is "the morning of Monday".
19161916

1917-
Instead of having keys in `$matches` be zero-based indexes, submatches can be named using the form
1917+
Instead of having keys in `$Matches` be zero-based indexes, submatches can be named using the form
19181918
`?<*name*>`. For example, `"((r)e)(d)"` can be written with three named submatches, `m1`, `m2`, and
19191919
`m3`, as follows: `"(?<m1>(?<m2>r)e)(?<m3>d)"`.
19201920

0 commit comments

Comments
 (0)