diff --git a/reference/5.1/CimCmdlets/Remove-CimInstance.md b/reference/5.1/CimCmdlets/Remove-CimInstance.md index a18aead3d678..9ad6ec4a99da 100644 --- a/reference/5.1/CimCmdlets/Remove-CimInstance.md +++ b/reference/5.1/CimCmdlets/Remove-CimInstance.md @@ -195,10 +195,10 @@ Accept wildcard characters: False Specifies a query to run on the CIM server. You can specify the query dialect using the **QueryDialect** parameter. -If the value specified contains double quotes ("), single quotes ('), or a backslash (\\), you must -escape those characters by prefixing them with the backslash (\\) character. If the value specified +If the value specified contains double quotes ("), single quotes ('), or a backslash (`\`), you must +escape those characters by prefixing them with the backslash (`\`) character. If the value specified uses the WQL LIKE operator, then you must escape the following characters by enclosing them in -square brackets (\[\]): percent (%), underscore (_), or opening square bracket (\[). +square brackets (`[]`): percent (%), underscore (`_`), or opening square bracket (`[`). ```yaml Type: System.String diff --git a/reference/5.1/Microsoft.PowerShell.Core/About/about_Debuggers.md b/reference/5.1/Microsoft.PowerShell.Core/About/about_Debuggers.md index b051da17957d..4f080a4d0610 100644 --- a/reference/5.1/Microsoft.PowerShell.Core/About/about_Debuggers.md +++ b/reference/5.1/Microsoft.PowerShell.Core/About/about_Debuggers.md @@ -765,8 +765,8 @@ PS C:\ps-test> Now, create a new command breakpoint with an action. The following command sets a command breakpoint with an action that logs the value of the `$scriptName` variable when the function is called. Because the Break keyword is not used in -the action, execution does not stop. (The backtick (`) is the line-continuation -character.) +the action, execution does not stop. (The backtick (`` ` ``) is the +line-continuation character.) ```powershell PS C:\ps-test> Set-PSBreakpoint -command psversion -script test.ps1 ` @@ -777,7 +777,7 @@ PS C:\ps-test> Set-PSBreakpoint -command psversion -script test.ps1 ` You can also add actions that set conditions for the breakpoint. In the following command, the command breakpoint is executed only if the execution policy is set to RemoteSigned, the most restrictive policy that still permits -you to run scripts. (The backtick (`) is the continuation character.) +you to run scripts. (The backtick (`` ` ``) is the continuation character.) ```powershell PS C:\ps-test> Set-PSBreakpoint -script test.ps1 -command psversion ` diff --git a/reference/5.1/Microsoft.PowerShell.Core/About/about_Properties.md b/reference/5.1/Microsoft.PowerShell.Core/About/about_Properties.md index fc8cda96aa3a..0862e219927f 100644 --- a/reference/5.1/Microsoft.PowerShell.Core/About/about_Properties.md +++ b/reference/5.1/Microsoft.PowerShell.Core/About/about_Properties.md @@ -124,7 +124,7 @@ You can also use the `Select-Object` and `Format-List` cmdlets to display the property values of an object. `Select-Object` and `Format-List` each have a **Property** parameter. You can use the **Property** parameter to specify one or more properties and their values. Or, you can use the wildcard character -(\*) to represent all the properties. +(`*`) to represent all the properties. For example, the following command displays the values of all the properties of the PowerShell.exe file. diff --git a/reference/5.1/Microsoft.PowerShell.Core/About/about_WQL.md b/reference/5.1/Microsoft.PowerShell.Core/About/about_WQL.md index ffabb74f44e1..fb1eea9a7a80 100644 --- a/reference/5.1/Microsoft.PowerShell.Core/About/about_WQL.md +++ b/reference/5.1/Microsoft.PowerShell.Core/About/about_WQL.md @@ -45,7 +45,7 @@ slowly. A typical WMI query begins with a Select statement that gets all properties or particular properties of a WMI class. To select all properties of a WMI class, -use an asterisk (\*). The From keyword specifies the WMI class. +use an asterisk (`*`). The From keyword specifies the WMI class. A Select statement has the following format: @@ -611,8 +611,8 @@ All operators, including the Like operators are valid with the Or and And operators. And, you can combine the Or and And operators in a single query with parentheses that tell Windows PowerShell which clauses to process first. -This command uses the Windows PowerShell continuation character (`) divide the -command into two lines. +This command uses the Windows PowerShell continuation character (`` ` ``) divide +the command into two lines. ```powershell $q = "Select * from Win32_Process ` diff --git a/reference/5.1/Microsoft.PowerShell.Management/Clear-Content.md b/reference/5.1/Microsoft.PowerShell.Management/Clear-Content.md index ae719a90f658..4361efa308d3 100644 --- a/reference/5.1/Microsoft.PowerShell.Management/Clear-Content.md +++ b/reference/5.1/Microsoft.PowerShell.Management/Clear-Content.md @@ -2,7 +2,7 @@ external help file: Microsoft.PowerShell.Commands.Management.dll-Help.xml Locale: en-US Module Name: Microsoft.PowerShell.Management -ms.date: 10/18/2018 +ms.date: 05/11/2022 online version: https://docs.microsoft.com/powershell/module/microsoft.powershell.management/clear-content?view=powershell-5.1&WT.mc_id=ps-gethelp schema: 2.0.0 title: Clear-Content @@ -17,22 +17,24 @@ Deletes the contents of an item, but does not delete the item. ### Path (Default) ``` -Clear-Content [-Path] [-Filter ] [-Include ] [-Exclude ] [-Force] - [-Credential ] [-WhatIf] [-Confirm] [-UseTransaction] [-Stream ] [] +Clear-Content [-Path] [-Filter ] [-Include ] [-Exclude ] +[-Force] [-Credential ] [-WhatIf] [-Confirm] [-UseTransaction] [-Stream ] +[] ``` ### LiteralPath ``` -Clear-Content -LiteralPath [-Filter ] [-Include ] [-Exclude ] [-Force] - [-Credential ] [-WhatIf] [-Confirm] [-UseTransaction] [-Stream ] [] +Clear-Content -LiteralPath [-Filter ] [-Include ] +[-Exclude ] [-Force] [-Credential ] [-WhatIf] [-Confirm] [-UseTransaction] +[-Stream ] [] ``` ## DESCRIPTION -The `Clear-Content` cmdlet deletes the contents of an item, such as deleting the text from a file, but it does not delete the item. -As a result, the item exists, but it is empty. -The `Clear-Content` is similar to `Clear-Item`, but it works on items with contents, instead of items with values. +The `Clear-Content` cmdlet deletes the contents of an item, such as deleting the text from a file, +but it does not delete the item. As a result, the item exists, but it is empty. `Clear-Content` is +similar to `Clear-Item`, but it works on items with contents, instead of items with values. ## EXAMPLES @@ -42,8 +44,8 @@ The `Clear-Content` is similar to `Clear-Item`, but it works on items with conte Clear-Content "..\SmpUsers\*\init.txt" ``` -This command deletes all of the content from the "init.txt" files in all subdirectories of the SmpUsers directory. -The files are not deleted, but they are empty. +This command deletes all of the content from the `init.txt` files in all subdirectories of the +`SmpUsers` directory. The files are not deleted, but they are empty. ### Example 2: Delete content of all files with a wildcard @@ -51,22 +53,28 @@ The files are not deleted, but they are empty. Clear-Content -Path "*" -Filter "*.log" -Force ``` -This command deletes the contents of all files in the current directory with the ".log" file name extension, including files with the read-only attribute. -The asterisk (\*) in the path represents all items in the current directory. -The **Force** parameter makes the command effective on read-only files. -Using a filter to restrict the command to files with the .log file name extension instead of specifying \*.log in the path makes the operation faster. +This command deletes the contents of all files in the current directory with the `.log` file name +extension, including files with the read-only attribute. The asterisk (`*`) in the path represents +all items in the current directory. The **Force** parameter makes the command effective on read-only +files. Using a filter to restrict the command to files with the `.log` file name extension instead +of specifying `*.log` in the path makes the operation faster. ### Example 3: Clear all data from a stream -This example shows how the `Clear-Content` cmdlet clears the content from an alternate data stream while leaving the stream intact. +This example shows how the `Clear-Content` cmdlet clears the content from an alternate data stream +while leaving the stream intact. -The first command uses the `Get-Content` cmdlet to get the content of the Zone.Identifier stream in the Copy-Script.ps1 file, which was downloaded from the Internet. +The first command uses the `Get-Content` cmdlet to get the content of the `Zone.Identifier` stream +in the `Copy-Script.ps1` file, which was downloaded from the internet. The second command uses the `Clear-Content` cmdlet to clear the content. -The third command repeats the first command. It verifies that the content is cleared, but the stream remains. If the stream were deleted, the command would generate an error. +The third command repeats the first command. It verifies that the content is cleared, but the stream +remains. If the stream were deleted, the command would generate an error. -You can use a method like this one to clear the content of an alternate data stream. However, it is not the recommended way to eliminate security checks that block files that are downloaded from the Internet. If you verify that a downloaded file is safe, use the `Unblock-File` cmdlet. +You can use a method like this one to clear the content of an alternate data stream. However, it is +not the recommended way to eliminate security checks that block files that are downloaded from the +Internet. If you verify that a downloaded file is safe, use the `Unblock-File` cmdlet. ```powershell Get-Content C:\Test\Copy-Script.ps1 -Stream Zone.Identifier @@ -92,7 +100,7 @@ Get-Content C:\Test\Copy-Script.ps1 -Stream Zone.Identifier > [!NOTE] > This parameter is not supported by any providers installed with PowerShell. To impersonate another -> user, or elevate your credentials when running this cmdlet, use Invoke-Command. +> user, or elevate your credentials when running this cmdlet, use `Invoke-Command`. ```yaml Type: System.Management.Automation.PSCredential @@ -108,10 +116,9 @@ Accept wildcard characters: False ### -Exclude -Specifies, as a string array, strings that this cmdlet omits from the path to the content. -The value of this parameter qualifies the **Path** parameter. -Enter a path element or pattern, such as "*.txt". -Wildcards are permitted. +Specifies, as a string array, strings that this cmdlet omits from the path to the content. The value +of this parameter qualifies the **Path** parameter. Enter a path element or pattern, such as +`*.txt`. Wildcards are permitted. ```yaml Type: System.String[] @@ -127,10 +134,10 @@ Accept wildcard characters: True ### -Filter -Specifies a filter in the provider's format or language. -The value of this parameter qualifies the **Path** parameter. -The syntax of the filter, including the use of wildcards, depends on the provider. -Filters are more efficient than other parameters, because the provider applies them when retrieving the objects, rather than having PowerShell filter the objects after they are retrieved. +Specifies a filter in the provider's format or language. The value of this parameter qualifies the +**Path** parameter. The syntax of the filter, including the use of wildcards, depends on the +provider. Filters are more efficient than other parameters, because the provider applies them when +retrieving the objects, rather than having PowerShell filter the objects after they are retrieved. ```yaml Type: System.String @@ -162,10 +169,8 @@ Accept wildcard characters: False ### -Include -Specifies, as a string array, content that this cmdlet clears. -The value of this parameter qualifies the **Path** parameter. -Enter a path element or pattern, such as "*.txt". -Wildcards are permitted. +Specifies, as a string array, content that this cmdlet clears. The value of this parameter qualifies +the **Path** parameter. Enter a path element or pattern, such as `*.txt`. Wildcards are permitted. ```yaml Type: System.String[] @@ -181,11 +186,10 @@ Accept wildcard characters: True ### -LiteralPath -Specifies the paths to the items from which content is deleted. -Unlike the **Path** parameter, the value of **LiteralPath** is used exactly as it is typed. -No characters are interpreted as wildcards. -If the path includes escape characters, enclose it in single quotation marks. -Single quotation marks tell having PowerShell not to interpret any characters as escape sequences. +Specifies the paths to the items from which content is deleted. Unlike the **Path** parameter, the +value of **LiteralPath** is used exactly as it is typed. No characters are interpreted as wildcards. +If the path includes escape characters, enclose it in single quotation marks (`'`). Single quotation +marks tell having PowerShell not to interpret any characters as escape sequences. ```yaml Type: System.String[] @@ -201,12 +205,10 @@ Accept wildcard characters: False ### -Path -Specifies the paths to the items from which content is deleted. -Wildcards are permitted. -The paths must be paths to items, not to containers. -For example, you must specify a path to one or more files, not a path to a directory. -Wildcards are permitted. -This parameter is required, but the parameter name ("Path") is optional. +Specifies the paths to the items from which content is deleted. Wildcards are permitted. The paths +must be paths to items, not to containers. For example, you must specify a path to one or more +files, not a path to a directory. Wildcards are permitted. This parameter is required, but the +parameter name (**Path**) is optional. ```yaml Type: System.String[] @@ -226,12 +228,14 @@ Specifies an alternative data stream for content. If the stream does not exist, this cmdlet creates it. Wildcard characters are not supported. -**Stream** is a dynamic parameter that the FileSystem provider adds to `Clear-Content`. -This parameter works only in file system drives. +**Stream** is a dynamic parameter that the FileSystem provider adds to `Clear-Content`. This +parameter works only in file system drives, and will clear the content of alternative data streams +on both files and directories. -You can use the `Clear-Content` cmdlet to change the content of the Zone.Identifier alternate data stream. -However, we do not recommend this as a way to eliminate security checks that block files that are downloaded from the Internet. -If you verify that a downloaded file is safe, use the `Unblock-File` cmdlet. +You can use the `Clear-Content` cmdlet to change the content of any alternate data stream, such as +`Zone.Identifier`. However, we do not recommend this as a way to eliminate security checks that +block files that are downloaded from the internet. If you verify that a downloaded file is safe, use +the `Unblock-File` cmdlet. This parameter was introduced in Windows PowerShell 3.0. @@ -249,9 +253,9 @@ Accept wildcard characters: False ### -UseTransaction -Includes the command in the active transaction. -This parameter is valid only when a transaction is in progress. -For more information, see [about_transactions](../Microsoft.PowerShell.Core/About/about_Transactions.md). +Includes the command in the active transaction. This parameter is valid only when a transaction is +in progress. For more information, see +[about_transactions](../Microsoft.PowerShell.Core/About/about_Transactions.md). ```yaml Type: System.Management.Automation.SwitchParameter @@ -283,8 +287,7 @@ Accept wildcard characters: False ### -WhatIf -Shows what would happen if the cmdlet runs. -The cmdlet is not run. +Shows what would happen if the cmdlet runs. The cmdlet is not run. ```yaml Type: System.Management.Automation.SwitchParameter @@ -300,7 +303,10 @@ Accept wildcard characters: False ### CommonParameters -This cmdlet supports the common parameters: `-Debug`, `-ErrorAction`, `-ErrorVariable`, `-InformationAction`, `-InformationVariable`, `-OutVariable`, `-OutBuffer`, `-PipelineVariable`, `-Verbose`, `-WarningAction`, and `-WarningVariable`. For more information, see [about_CommonParameters](../Microsoft.PowerShell.Core/About/about_CommonParameters.md). +This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, +-InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, +-WarningAction, and -WarningVariable. For more information, see +[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216). ## INPUTS @@ -316,8 +322,9 @@ This cmdlet does not return any objects. ## NOTES -You can use `Clear-Content` with the PowerShell FileSystem provider and with other providers that manipulate content. -To clear items that are not considered to be content, such as items managed by the PowerShell Certificate or Registry providers, use `Clear-Item`. +You can use `Clear-Content` with the PowerShell FileSystem provider and with other providers that +manipulate content. To clear items that are not considered to be content, such as items managed by +the PowerShell Certificate or Registry providers, use `Clear-Item`. The `Clear-Content` cmdlet is designed to work with the data exposed by any provider. To list the providers available in your session, type `Get-PsProvider`. diff --git a/reference/5.1/Microsoft.PowerShell.Management/Get-ItemProperty.md b/reference/5.1/Microsoft.PowerShell.Management/Get-ItemProperty.md index 71322a0b147c..fe14f84d3733 100644 --- a/reference/5.1/Microsoft.PowerShell.Management/Get-ItemProperty.md +++ b/reference/5.1/Microsoft.PowerShell.Management/Get-ItemProperty.md @@ -2,7 +2,7 @@ external help file: Microsoft.PowerShell.Commands.Management.dll-Help.xml Locale: en-US Module Name: Microsoft.PowerShell.Management -ms.date: 05/25/2021 +ms.date: 05/11/2022 online version: https://docs.microsoft.com/powershell/module/microsoft.powershell.management/get-itemproperty?view=powershell-5.1&WT.mc_id=ps-gethelp schema: 2.0.0 title: Get-ItemProperty @@ -24,21 +24,22 @@ Get-ItemProperty [-Path] [[-Name] ] [-Filter ] [-In ### LiteralPath ``` -Get-ItemProperty -LiteralPath [[-Name] ] [-Filter ] [-Include ] - [-Exclude ] [-Credential ] [-UseTransaction] [] +Get-ItemProperty -LiteralPath [[-Name] ] [-Filter ] +[-Include ] [-Exclude ] [-Credential ] [-UseTransaction] +[] ``` ## DESCRIPTION The `Get-ItemProperty` cmdlet gets the properties of the specified items. For example, you can use -this cmdlet to get the value of the LastAccessTime property of a file object. You can also use this -cmdlet to view registry entries and their values. +this cmdlet to get the value of the **LastAccessTime** property of a file object. You can also use +this cmdlet to view registry entries and their values. ## EXAMPLES ### Example 1: Get information about a specific directory -This command gets information about the "C:\Windows" directory. +This command gets information about the `C:\Windows` directory. ```powershell Get-ItemProperty C:\Windows @@ -53,44 +54,36 @@ This command gets the properties of the `C:\Test\Weather.xls` file. The result i Get-ItemProperty C:\Test\Weather.xls | Format-List ``` -### Example 3: Display the value name and data of registry entries in a registry subkey - -This command displays the value name and data of each of the registry entries contained in the -"CurrentVersion" registry subkey. Note that the command requires that there is a PowerShell drive -named `HKLM:` that is mapped to the `HKEY_LOCAL_MACHINE` hive of the registry. A drive with that -name and mapping is available in PowerShell by default. Alternatively, the path to this registry -subkey can be specified by using the following alternative path that begins with the provider name -followed by two colons: - -`Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion` - -```powershell -Get-ItemProperty -Path HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion -``` - -### Example 4: Get the value name and data of a registry entry in a registry subkey +### Example 3: Get the value name and data of a registry entry in a registry subkey This command gets the value name and data of the `ProgramFilesDir` registry entry in the -`CurrentVersion` registry subkey. The command uses the **Path** parameter to specify the subkey and -the Name parameter to specify the value name of the entry. - -The command uses a back tick or grave accent (\`), the PowerShell continuation character, to -continue the command on the second line. +`CurrentVersion` registry subkey. The **Path** specifies the subkey and the **Name** parameter +specifies the value name of the entry. ```powershell Get-ItemProperty -Path HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion -Name "ProgramFilesDir" ``` -### Example 5: Get the value names and data of registry entries in a registry key +> [!NOTE] +> This command requires that there is a PowerShell drive named `HKLM:` that is mapped to the +> `HKEY_LOCAL_MACHINE` hive of the registry. +> +> A drive with that name and mapping is available in PowerShell by default. Alternatively, the path +> to this registry subkey can be specified by using the following alternative path that begins with +> the provider name followed by two colons: +> +> `Registry::HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion`. + +### Example 4: Get the value names and data of registry entries in a registry key -This command gets the value names and data of the registry entries in the "PowerShellEngine" +This command gets the value names and data of the registry entries in the `PowerShellEngine` registry key. The results are shown in the following sample output. ```powershell Get-ItemProperty -Path HKLM:\SOFTWARE\Microsoft\PowerShell\1\PowerShellEngine ``` -```output +```Output ApplicationBase : C:\Windows\system32\WindowsPowerShell\v1.0\ ConsoleHostAssemblyName : Microsoft.PowerShell.ConsoleHost, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, ProcessorArchitecture=msil PowerShellVersion : 2.0 @@ -99,66 +92,14 @@ CTPVersion : 5 PSCompatibleVersion : 1.0,2.0 ``` -### Example 6: Get, format, and display the results of registry values and data - -This example shows how to format the output of a `Get-ItemProperty` command in a list to make it -easy to see the registry values and data and to make it easy to interpret the results. - -The first command uses the `Get-ItemProperty` cmdlet to get the registry entries in the -`Microsoft.PowerShell` subkey. This subkey stores options for the default shell for PowerShell. The -results are shown in the following sample output. - -The output shows that there are two registry entries, `Path` and `ExecutionPolicy`. When a registry -key contains fewer than five entries, by default it is displayed in a table, but it is often easier -to view in a list. - -The second command uses the same `Get-ItemProperty` command. However, this time, the command uses a -pipeline operator (`|`) to send the results of the command to the `Format-List` cmdlet. The -`Format-List` command uses the Property parameter with a value of '*' (all) to display all of the -properties of the objects in a list. The results are shown in the following sample output. - -The resulting display shows the `Path` and `ExecutionPolicy` registry entries, along with several -less familiar properties of the registry key object. The other properties, prefixed with PS, are -properties of PowerShell custom objects, such as the objects that represent the registry keys. - -```powershell -Get-ItemProperty -Path HKLM:\SOFTWARE\Microsoft\PowerShell\1\ShellIds\Microsoft.PowerShell -``` - -```output -Path ExecutionPolicy ----- --------------- -C:\Windows\system32\WindowsPowerShell\v1.0\powershell.exe RemoteSigned -``` - -```powershell -Get-ItemProperty -Path HKLM:\SOFTWARE\Microsoft\PowerShell\1\ShellIds\Microsoft.PowerShell | Format-List -Property * -``` - -```output -PSPath : Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\Software\Microsoft\PowerShell\1\ShellIds\Micro -soft.PowerShell -PSParentPath : Microsoft.PowerShell.Core\Registry::HKEY_LOCAL_MACHINE\Software\Microsoft\PowerShell\1\ShellIds -PSChildName : Microsoft.PowerShell -PSDrive : HKLM -PSProvider : Microsoft.PowerShell.Core\Registry -Path : C:\Windows\system32\WindowsPowerShell\v1.0\powershell.exe -ExecutionPolicy : RemoteSigned -``` - ## PARAMETERS ### -Credential -Specifies a user account that has permission to perform this action. The default is the current -user. - -Type a user name, such as "User01" or "Domain01\User01", or enter a **PSCredential** object, such as -one generated by the `Get-Credential` cmdlet. If you type a user name, you are prompted for a -password. - -> [!WARNING] -> This parameter is not supported by any providers installed with Windows PowerShell. +> [!NOTE] +> This parameter is not supported by any providers installed with Windows PowerShell. To impersonate +> another user, or elevate your credentials when running this cmdlet, use +> [Invoke-Command](../Microsoft.PowerShell.Core/Invoke-Command.md). ```yaml Type: System.Management.Automation.PSCredential @@ -174,9 +115,11 @@ Accept wildcard characters: False ### -Exclude -Specifies, as a string array, an item or items that this cmdlet excludes from the operation. The -value of this parameter qualifies the **Path** parameter. Enter a path element or pattern, such as -"*.txt". Wildcard characters are permitted. +Specifies, as a string array, an item or items that this cmdlet excludes in the operation. The value +of this parameter qualifies the **Path** parameter. Enter a path element or pattern, such as +`*.txt`. Wildcard characters are permitted. The **Exclude** parameter is effective only when the +command includes the contents of an item, such as `C:\Windows\*`, where the wildcard character +specifies the contents of the `C:\Windows` directory. ```yaml Type: System.String[] @@ -187,17 +130,18 @@ Required: False Position: Named Default value: None Accept pipeline input: False -Accept wildcard characters: False +Accept wildcard characters: True ``` ### -Filter -Specifies a filter in the format or language of the provider. The value of this parameter qualifies -the **Path** parameter. - -The syntax of the filter, including the use of wildcard characters, depends on the provider. Filters -are more efficient than other parameters, because the provider applies them when the cmdlet gets the -objects rather than having PowerShell filter the objects after they are retrieved. +Specifies a filter to qualify the **Path** parameter. The +[FileSystem](../Microsoft.PowerShell.Core/About/about_FileSystem_Provider.md) provider is the only +installed PowerShell provider that supports the use of filters. You can find the syntax for the +**FileSystem** filter language in +[about_Wildcards](../Microsoft.PowerShell.Core/About/about_Wildcards.md). Filters are more efficient +than other parameters, because the provider applies them when the cmdlet gets the objects rather +than having PowerShell filter the objects after they are retrieved. ```yaml Type: System.String @@ -215,7 +159,9 @@ Accept wildcard characters: True Specifies, as a string array, an item or items that this cmdlet includes in the operation. The value of this parameter qualifies the **Path** parameter. Enter a path element or pattern, such as -"*.txt". Wildcard characters are permitted. +`*.txt`. Wildcard characters are permitted. The **Include** parameter is effective only when the +command includes the contents of an item, such as `C:\Windows\*`, where the wildcard character +specifies the contents of the `C:\Windows` directory. ```yaml Type: System.String[] @@ -226,15 +172,18 @@ Required: False Position: Named Default value: None Accept pipeline input: False -Accept wildcard characters: False +Accept wildcard characters: True ``` ### -LiteralPath -Specifies the path to the current location of the property. Unlike the **Path** parameter, the value -of **LiteralPath** is used exactly as it is typed. No characters are interpreted as wildcards. If -the path includes escape characters, enclose it in single quotation marks. Single quotation marks -tell PowerShell not to interpret any characters as escape sequences. +Specifies the path to the current location of the property. The value of **LiteralPath** is used +exactly as it is typed. No characters are interpreted as wildcards. If the path includes escape +characters, enclose it in single quotation marks (`'`). Single quotation marks tell PowerShell not +to interpret any characters as escape sequences. + +For more information, see +[about_Quoting_Rules](../Microsoft.Powershell.Core/About/about_Quoting_Rules.md). ```yaml Type: System.String[] @@ -283,8 +232,8 @@ Accept wildcard characters: False ### -UseTransaction Includes the command in the active transaction. This parameter is valid only when a transaction is -in progress. For more information, see Includes the command in the active transaction. This -parameter is valid only when a transaction is in progress. For more information, see [about_Transactions](../Microsoft.PowerShell.Core/About/about_Transactions.md). +in progress. For more information, see +[about_Transactions](../Microsoft.PowerShell.Core/About/about_Transactions.md). ```yaml Type: System.Management.Automation.SwitchParameter @@ -300,7 +249,10 @@ Accept wildcard characters: False ### CommonParameters -This cmdlet supports the common parameters: `-Debug`, `-ErrorAction`, `-ErrorVariable`, `-InformationAction`, `-InformationVariable`, `-OutVariable`, `-OutBuffer`, `-PipelineVariable`, `-Verbose`, `-WarningAction`, and `-WarningVariable`. For more information, see [about_CommonParameters](../Microsoft.PowerShell.Core/About/about_CommonParameters.md). +This cmdlet supports the common parameters: `-Debug`, `-ErrorAction`, `-ErrorVariable`, +`-InformationAction`, `-InformationVariable`, `-OutVariable`, `-OutBuffer`, `-PipelineVariable`, +`-Verbose`, `-WarningAction`, and `-WarningVariable`. For more information, see +[about_CommonParameters](../Microsoft.PowerShell.Core/About/about_CommonParameters.md). ## INPUTS @@ -318,8 +270,8 @@ the object that is retrieved. For example, in a file system drive, it might retu ## NOTES The `Get-ItemProperty` cmdlet is designed to work with the data exposed by any provider. To list the -providers available in your session, type "`Get-PSProvider`". For more information, see -about_Providers. +providers available in your session, type `Get-PSProvider`. For more information, see +[about_Providers](../Microsoft.PowerShell.Core/About/about_Providers.md). ## RELATED LINKS @@ -336,3 +288,5 @@ about_Providers. [Rename-ItemProperty](Rename-ItemProperty.md) [Set-ItemProperty](Set-ItemProperty.md) + +[about_Providers](../Microsoft.PowerShell.Core/About/about_Providers.md) diff --git a/reference/5.1/Microsoft.PowerShell.Management/Move-Item.md b/reference/5.1/Microsoft.PowerShell.Management/Move-Item.md index a7aa3dd427ed..e70823b023ad 100644 --- a/reference/5.1/Microsoft.PowerShell.Management/Move-Item.md +++ b/reference/5.1/Microsoft.PowerShell.Management/Move-Item.md @@ -2,7 +2,7 @@ external help file: Microsoft.PowerShell.Commands.Management.dll-Help.xml Locale: en-US Module Name: Microsoft.PowerShell.Management -ms.date: 10/18/2018 +ms.date: 05/11/2022 online version: https://docs.microsoft.com/powershell/module/microsoft.powershell.management/move-item?view=powershell-5.1&WT.mc_id=ps-gethelp schema: 2.0.0 title: Move-Item @@ -32,16 +32,19 @@ Move-Item -LiteralPath [[-Destination] ] [-Force] [-Filter