diff --git a/reference/5.1/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md b/reference/5.1/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md index 65c7fff7b7c9..72fb0b9d71a3 100644 --- a/reference/5.1/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md +++ b/reference/5.1/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md @@ -869,4 +869,4 @@ Displays information about PowerShell cmdlets and concepts. - [about_Functions](about_Functions.md) - [about_Functions_Advanced_Parameters](about_Functions_Advanced_Parameters.md) - [about_Scripts](about_Scripts.md) -- [How to Write Cmdlet Help](https://go.microsoft.com/fwlink/?LinkID=123415) +- [Writing Comment-Based Help Topics](/powershell/scripting/developer/help/writing-comment-based-help-topics) diff --git a/reference/5.1/Microsoft.PowerShell.Core/About/about_Environment_Variables.md b/reference/5.1/Microsoft.PowerShell.Core/About/about_Environment_Variables.md index 1b004c55f168..7e9f9cc6b4ae 100644 --- a/reference/5.1/Microsoft.PowerShell.Core/About/about_Environment_Variables.md +++ b/reference/5.1/Microsoft.PowerShell.Core/About/about_Environment_Variables.md @@ -1,7 +1,7 @@ --- description: Describes how to access and manage environment variables in PowerShell. Locale: en-US -ms.date: 04/22/2024 +ms.date: 09/05/2024 online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_environment_variables?view=powershell-5.1&WT.mc_id=ps-gethelp schema: 2.0.0 title: about_Environment_Variables @@ -14,10 +14,10 @@ Describes how to access and manage environment variables in PowerShell. Environment variables store data that's used by the operating system and other programs. PowerShell creates the following environment variables: -- **PSExecutionPolicyPreference** -- **PSModulePath** -- **PSModuleAnalysisCachePath** -- **PSDisableModuleAnalysisCacheCleanup** +- `PSExecutionPolicyPreference` +- `PSModulePath` +- `PSModuleAnalysisCachePath` +- `PSDisableModuleAnalysisCacheCleanup` For full descriptions of these variables, see the [PowerShell environment variables][03] of this article. @@ -308,7 +308,7 @@ preference variables, see [about_Preference_Variables][06]. The environment variables that store preferences include: -- **PSExecutionPolicyPreference** +- `PSExecutionPolicyPreference` Stores the execution policy set for the current session. This environment variable exists only when you set an execution policy for a single session. @@ -326,7 +326,7 @@ The environment variables that store preferences include: This information only applies to the Windows platform. For more information, see [about_Execution_Policies][05]. -- **PSModulePath** +- `PSModulePath` The `$env:PSModulePath` environment variable contains a list of folder locations that are searched to find modules and resources. @@ -352,7 +352,7 @@ The environment variables that store preferences include: For more information, see [about_PSModulePath][08]. -- **PSModuleAnalysisCachePath** +- `PSModuleAnalysisCachePath` PowerShell provides control over the file that's used to cache data about modules and their cmdlets. The cache is read at startup while searching for a @@ -396,7 +396,7 @@ The environment variables that store preferences include: } ``` -- **PSDisableModuleAnalysisCacheCleanup** +- `PSDisableModuleAnalysisCacheCleanup` When writing out the module analysis cache, PowerShell checks for modules that no longer exist to avoid an unnecessarily large cache. Sometimes these @@ -413,13 +413,13 @@ The environment variables that store preferences include: ### Path information -- **PATH** +- `PATH` The `$env:PATH` environment variable contains a list of folder locations that the operating system searches for executable files. On Windows, the list of folder locations is separated by the semi-colon (`;`) character. -- **PATHEXT** +- `PATHEXT` The `$env:PATHEXT` variable contains a list of file extensions that Windows considers to be executable files. When a script file with one of the listed diff --git a/reference/5.1/Microsoft.PowerShell.Core/About/about_Path_Syntax.md b/reference/5.1/Microsoft.PowerShell.Core/About/about_Path_Syntax.md index 6c4043481bc9..a222258c1246 100644 --- a/reference/5.1/Microsoft.PowerShell.Core/About/about_Path_Syntax.md +++ b/reference/5.1/Microsoft.PowerShell.Core/About/about_Path_Syntax.md @@ -1,7 +1,7 @@ --- description: Describes the full and relative path formats in PowerShell. Locale: en-US -ms.date: 09/16/2023 +ms.date: 09/05/2024 online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_path_syntax?view=powershell-5.1&WT.mc_id=ps-gethelp schema: 2.0.0 title: about_Path_Syntax @@ -18,9 +18,9 @@ uniquely identified by their path names. A path is a combination of the item name, the container and subcontainers in which the item is located, and the PowerShell drive through which the containers are accessed. -In PowerShell, pathnames can be one of two types: _fully qualified_ and +In PowerShell, path names can be one of two types: _fully qualified_ and _relative_. A fully qualified path consists of all elements that make up a -path. The following syntax shows the elements in a fully qualified path name: +path. The following syntax shows the elements in a fully qualified path: ```Syntax [::]:[\[\...]]\ @@ -115,11 +115,35 @@ first file (`C:\TechDocs\Jan\Results.txt`) and the path for the second file (`C:\TechDocs\Feb\Results.txt`) allow you to clearly distinguish between the two files. +## Support for the Win32 File namespace + +On Windows, the cmdlets that support the FileSystem provider also support the +paths that use the Win32 File namespace format. You can only use these paths +with the **LiteralPath** parameter of the cmdlets. + +Paths in Win32 File namespace are prefixed with `\\?\`. The prefix tells the +Windows APIs to disable all string parsing and send the string that follows +directly to the file system. For example, if the file system supports large +paths and file names, you can exceed the **MAX_PATH** limits that are otherwise +enforced by the Windows APIs. + +For more information, see _Win32 File Namespaces_ in +[Naming Files, Paths, and Namespaces][01]. + ## See also -- [about_Locations](about_Locations.md) -- [Convert-Path](xref:Microsoft.PowerShell.Management.Convert-Path) -- [Join-Path](xref:Microsoft.PowerShell.Management.Join-Path) -- [Resolve-Path](xref:Microsoft.PowerShell.Management.Resolve-Path) -- [Split-Path](xref:Microsoft.PowerShell.Management.Split-Path) -- [Test-Path](xref:Microsoft.PowerShell.Management.Test-Path) +- [about_Locations][02] +- [Convert-Path][03] +- [Join-Path][04] +- [Resolve-Path][05] +- [Split-Path][06] +- [Test-Path][07] + + +[01]: /windows/win32/fileio/naming-a-file#win32-file-namespaces +[02]: about_Locations.md +[03]: xref:Microsoft.PowerShell.Management.Convert-Path +[04]: xref:Microsoft.PowerShell.Management.Join-Path +[05]: xref:Microsoft.PowerShell.Management.Resolve-Path +[06]: xref:Microsoft.PowerShell.Management.Split-Path +[07]: xref:Microsoft.PowerShell.Management.Test-Path diff --git a/reference/7.2/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md b/reference/7.2/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md index 9bc53b833e77..e675341548e9 100644 --- a/reference/7.2/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md +++ b/reference/7.2/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md @@ -869,4 +869,4 @@ Displays information about PowerShell cmdlets and concepts. - [about_Functions](about_Functions.md) - [about_Functions_Advanced_Parameters](about_Functions_Advanced_Parameters.md) - [about_Scripts](about_Scripts.md) -- [How to Write Cmdlet Help](https://go.microsoft.com/fwlink/?LinkID=123415) +- [Writing Comment-Based Help Topics](/powershell/scripting/developer/help/writing-comment-based-help-topics) diff --git a/reference/7.2/Microsoft.PowerShell.Core/About/about_Environment_Variables.md b/reference/7.2/Microsoft.PowerShell.Core/About/about_Environment_Variables.md index 85c821ca0a8e..674e07c66a6f 100644 --- a/reference/7.2/Microsoft.PowerShell.Core/About/about_Environment_Variables.md +++ b/reference/7.2/Microsoft.PowerShell.Core/About/about_Environment_Variables.md @@ -1,7 +1,7 @@ --- description: Describes how to access and manage environment variables in PowerShell. Locale: en-US -ms.date: 04/22/2024 +ms.date: 09/05/2024 online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_environment_variables?view=powershell-7.2&WT.mc_id=ps-gethelp schema: 2.0.0 title: about_Environment_Variables @@ -14,13 +14,13 @@ Describes how to access and manage environment variables in PowerShell. Environment variables store data that's used by the operating system and other programs. PowerShell creates the following environment variables: -- **POWERSHELL_TELEMETRY_OPTOUT** -- **POWERSHELL_DISTRIBUTION_CHANNEL** -- **POWERSHELL_UPDATECHECK** -- **PSExecutionPolicyPreference** -- **PSModulePath** -- **PSModuleAnalysisCachePath** -- **PSDisableModuleAnalysisCacheCleanup** +- `POWERSHELL_TELEMETRY_OPTOUT` +- `POWERSHELL_DISTRIBUTION_CHANNEL` +- `POWERSHELL_UPDATECHECK` +- `PSExecutionPolicyPreference` +- `PSModulePath` +- `PSModuleAnalysisCachePath` +- `PSDisableModuleAnalysisCacheCleanup` For full descriptions of these variables, see the [PowerShell environment variables][03] of this article. @@ -339,7 +339,7 @@ preference variables, see [about_Preference_Variables][06]. The environment variables that store preferences include: -- **POWERSHELL_TELEMETRY_OPTOUT** +- `POWERSHELL_TELEMETRY_OPTOUT` To opt-out of telemetry, set the environment variable to `true`, `yes`, or `1`. For more information, see [about_Telemetry][09]. @@ -348,7 +348,7 @@ The environment variables that store preferences include: starting the PowerShell process. See the previous sections for information about creating persistent environment variables. -- **POWERSHELL_DISTRIBUTION_CHANNEL** +- `POWERSHELL_DISTRIBUTION_CHANNEL` Beginning in PowerShell 7.2, this environment variable is set by the installer packages to record the method and source of installation for @@ -357,7 +357,7 @@ The environment variables that store preferences include: This information is included in the telemetry data sent to Microsoft. Users shouldn't change this value. -- **POWERSHELL_UPDATECHECK** +- `POWERSHELL_UPDATECHECK` The update notification behavior can be changed using the `POWERSHELL_UPDATECHECK` environment variable. For more information, see @@ -375,7 +375,7 @@ The environment variables that store preferences include: PowerShell process. See the previous sections for information about creating persistent environment variables. -- **PSExecutionPolicyPreference** +- `PSExecutionPolicyPreference` Stores the execution policy set for the current session. This environment variable exists only when you set an execution policy for a single session. @@ -393,7 +393,7 @@ The environment variables that store preferences include: This information only applies to the Windows platform. For more information, see [about_Execution_Policies][05]. -- **PSModulePath** +- `PSModulePath` The `$env:PSModulePath` environment variable contains a list of folder locations that are searched to find modules and resources. On Windows, the @@ -425,7 +425,7 @@ The environment variables that store preferences include: For more information, see [about_PSModulePath][08]. -- **PSModuleAnalysisCachePath** +- `PSModuleAnalysisCachePath` PowerShell provides control over the file that's used to cache data about modules and their cmdlets. The cache is read at startup while searching for a @@ -474,7 +474,7 @@ The environment variables that store preferences include: } ``` -- **PSDisableModuleAnalysisCacheCleanup** +- `PSDisableModuleAnalysisCacheCleanup` When writing out the module analysis cache, PowerShell checks for modules that no longer exist to avoid an unnecessarily large cache. Sometimes these @@ -491,7 +491,7 @@ The environment variables that store preferences include: ### Path information -- **PATH** +- `PATH` The `$env:PATH` environment variable contains a list of folder locations that the operating system searches for executable files. On Windows, the list of @@ -499,7 +499,7 @@ The environment variables that store preferences include: non-Windows platforms, the colon (`:`) separates the folder locations in the environment variable. -- **PATHEXT** +- `PATHEXT` The `$env:PATHEXT` variable contains a list of file extensions that Windows considers to be executable files. When a script file with one of the listed @@ -519,23 +519,23 @@ The environment variables that store preferences include: PowerShell scripts always start in the current console session. You don't need to add the `.PS1` extension. -- **XDG** variables +- `XDG` variables On non-Windows platforms, PowerShell uses the following XDG environment variables as defined by the [XDG Base Directory Specification][13]. - - **XDG_CONFIG_HOME** - - **XDG_DATA_HOME** - - **XDG_CACHE_HOME** + - `XDG_CONFIG_HOME` + - `XDG_DATA_HOME` + - `XDG_CACHE_HOME` ### Terminal features Beginning in PowerShell 7.2, the following environment variables can be used to control the Virtual Terminal features like ANSI escape sequences that colorize -output. Support for ANSI escape sequences can be turned off using the **TERM** -or **NO_COLOR** environment variables. +output. Support for ANSI escape sequences can be turned off using the `TERM` +or `NO_COLOR` environment variables. -- **TERM** +- `TERM` The following values of `$env:TERM` change the behavior as follows: @@ -543,10 +543,10 @@ or **NO_COLOR** environment variables. - `xterm-mono` - sets `$PSStyle.OutputRendering = PlainText` - `xtermm` - sets `$PSStyle.OutputRendering = PlainText` -- **NO_COLOR** +- `NO_COLOR` If `$env:NO_COLOR` exists, then `$PSStyle.OutputRendering` is set to - **PlainText**. For more information about the **NO_COLOR** environment + `PlainText`. For more information about the `NO_COLOR` environment variable, see [https://no-color.org/][12]. ## See also diff --git a/reference/7.2/Microsoft.PowerShell.Core/About/about_Path_Syntax.md b/reference/7.2/Microsoft.PowerShell.Core/About/about_Path_Syntax.md index 5e872b3e9714..6cdcc708d504 100644 --- a/reference/7.2/Microsoft.PowerShell.Core/About/about_Path_Syntax.md +++ b/reference/7.2/Microsoft.PowerShell.Core/About/about_Path_Syntax.md @@ -1,7 +1,7 @@ --- description: Describes the full and relative path formats in PowerShell. Locale: en-US -ms.date: 09/16/2023 +ms.date: 09/05/2024 online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_path_syntax?view=powershell-7.2&WT.mc_id=ps-gethelp schema: 2.0.0 title: about_Path_Syntax @@ -18,9 +18,9 @@ uniquely identified by their path names. A path is a combination of the item name, the container and subcontainers in which the item is located, and the PowerShell drive through which the containers are accessed. -In PowerShell, pathnames can be one of two types: _fully qualified_ and +In PowerShell, path names can be one of two types: _fully qualified_ and _relative_. A fully qualified path consists of all elements that make up a -path. The following syntax shows the elements in a fully qualified path name: +path. The following syntax shows the elements in a fully qualified path: ```Syntax [::]:[\[\...]]\ @@ -115,11 +115,35 @@ first file (`C:\TechDocs\Jan\Results.txt`) and the path for the second file (`C:\TechDocs\Feb\Results.txt`) allow you to clearly distinguish between the two files. +## Support for the Win32 File namespace + +On Windows, the cmdlets that support the FileSystem provider also support the +paths that use the Win32 File namespace format. You can only use these paths +with the **LiteralPath** parameter of the cmdlets. + +Paths in Win32 File namespace are prefixed with `\\?\`. The prefix tells the +Windows APIs to disable all string parsing and send the string that follows +directly to the file system. For example, if the file system supports large +paths and file names, you can exceed the **MAX_PATH** limits that are otherwise +enforced by the Windows APIs. + +For more information, see _Win32 File Namespaces_ in +[Naming Files, Paths, and Namespaces][01]. + ## See also -- [about_Locations](about_Locations.md) -- [Convert-Path](xref:Microsoft.PowerShell.Management.Convert-Path) -- [Join-Path](xref:Microsoft.PowerShell.Management.Join-Path) -- [Resolve-Path](xref:Microsoft.PowerShell.Management.Resolve-Path) -- [Split-Path](xref:Microsoft.PowerShell.Management.Split-Path) -- [Test-Path](xref:Microsoft.PowerShell.Management.Test-Path) +- [about_Locations][02] +- [Convert-Path][03] +- [Join-Path][04] +- [Resolve-Path][05] +- [Split-Path][06] +- [Test-Path][07] + + +[01]: /windows/win32/fileio/naming-a-file#win32-file-namespaces +[02]: about_Locations.md +[03]: xref:Microsoft.PowerShell.Management.Convert-Path +[04]: xref:Microsoft.PowerShell.Management.Join-Path +[05]: xref:Microsoft.PowerShell.Management.Resolve-Path +[06]: xref:Microsoft.PowerShell.Management.Split-Path +[07]: xref:Microsoft.PowerShell.Management.Test-Path diff --git a/reference/7.4/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md b/reference/7.4/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md index 5faadf62fa13..69727f8bc5ff 100644 --- a/reference/7.4/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md +++ b/reference/7.4/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md @@ -869,4 +869,4 @@ Displays information about PowerShell cmdlets and concepts. - [about_Functions](about_Functions.md) - [about_Functions_Advanced_Parameters](about_Functions_Advanced_Parameters.md) - [about_Scripts](about_Scripts.md) -- [How to Write Cmdlet Help](https://go.microsoft.com/fwlink/?LinkID=123415) +- [Writing Comment-Based Help Topics](/powershell/scripting/developer/help/writing-comment-based-help-topics) diff --git a/reference/7.4/Microsoft.PowerShell.Core/About/about_Environment_Variables.md b/reference/7.4/Microsoft.PowerShell.Core/About/about_Environment_Variables.md index 6cb2b03dd927..8e464c4d89ce 100644 --- a/reference/7.4/Microsoft.PowerShell.Core/About/about_Environment_Variables.md +++ b/reference/7.4/Microsoft.PowerShell.Core/About/about_Environment_Variables.md @@ -1,7 +1,7 @@ --- description: Describes how to access and manage environment variables in PowerShell. Locale: en-US -ms.date: 04/22/2024 +ms.date: 09/05/2024 online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_environment_variables?view=powershell-7.4&WT.mc_id=ps-gethelp schema: 2.0.0 title: about_Environment_Variables @@ -14,13 +14,13 @@ Describes how to access and manage environment variables in PowerShell. Environment variables store data that's used by the operating system and other programs. PowerShell creates the following environment variables: -- **POWERSHELL_TELEMETRY_OPTOUT** -- **POWERSHELL_DISTRIBUTION_CHANNEL** -- **POWERSHELL_UPDATECHECK** -- **PSExecutionPolicyPreference** -- **PSModulePath** -- **PSModuleAnalysisCachePath** -- **PSDisableModuleAnalysisCacheCleanup** +- `POWERSHELL_TELEMETRY_OPTOUT` +- `POWERSHELL_DISTRIBUTION_CHANNEL` +- `POWERSHELL_UPDATECHECK` +- `PSExecutionPolicyPreference` +- `PSModulePath` +- `PSModuleAnalysisCachePath` +- `PSDisableModuleAnalysisCacheCleanup` For full descriptions of these variables, see the [PowerShell environment variables][03] of this article. @@ -339,7 +339,7 @@ preference variables, see [about_Preference_Variables][06]. The environment variables that store preferences include: -- **POWERSHELL_TELEMETRY_OPTOUT** +- `POWERSHELL_TELEMETRY_OPTOUT` To opt-out of telemetry, set the environment variable to `true`, `yes`, or `1`. For more information, see [about_Telemetry][09]. @@ -348,7 +348,7 @@ The environment variables that store preferences include: starting the PowerShell process. See the previous sections for information about creating persistent environment variables. -- **POWERSHELL_DISTRIBUTION_CHANNEL** +- `POWERSHELL_DISTRIBUTION_CHANNEL` Beginning in PowerShell 7.2, this environment variable is set by the installer packages to record the method and source of installation for @@ -357,7 +357,7 @@ The environment variables that store preferences include: This information is included in the telemetry data sent to Microsoft. Users shouldn't change this value. -- **POWERSHELL_UPDATECHECK** +- `POWERSHELL_UPDATECHECK` The update notification behavior can be changed using the `POWERSHELL_UPDATECHECK` environment variable. For more information, see @@ -375,7 +375,7 @@ The environment variables that store preferences include: PowerShell process. See the previous sections for information about creating persistent environment variables. -- **PSExecutionPolicyPreference** +- `PSExecutionPolicyPreference` Stores the execution policy set for the current session. This environment variable exists only when you set an execution policy for a single session. @@ -393,7 +393,7 @@ The environment variables that store preferences include: This information only applies to the Windows platform. For more information, see [about_Execution_Policies][05]. -- **PSModulePath** +- `PSModulePath` The `$env:PSModulePath` environment variable contains a list of folder locations that are searched to find modules and resources. On Windows, the @@ -425,7 +425,7 @@ The environment variables that store preferences include: For more information, see [about_PSModulePath][08]. -- **PSModuleAnalysisCachePath** +- `PSModuleAnalysisCachePath` PowerShell provides control over the file that's used to cache data about modules and their cmdlets. The cache is read at startup while searching for a @@ -474,7 +474,7 @@ The environment variables that store preferences include: } ``` -- **PSDisableModuleAnalysisCacheCleanup** +- `PSDisableModuleAnalysisCacheCleanup` When writing out the module analysis cache, PowerShell checks for modules that no longer exist to avoid an unnecessarily large cache. Sometimes these @@ -491,7 +491,7 @@ The environment variables that store preferences include: ### Path information -- **PATH** +- `PATH` The `$env:PATH` environment variable contains a list of folder locations that the operating system searches for executable files. On Windows, the list of @@ -499,7 +499,7 @@ The environment variables that store preferences include: non-Windows platforms, the colon (`:`) separates the folder locations in the environment variable. -- **PATHEXT** +- `PATHEXT` The `$env:PATHEXT` variable contains a list of file extensions that Windows considers to be executable files. When a script file with one of the listed @@ -519,23 +519,23 @@ The environment variables that store preferences include: PowerShell scripts always start in the current console session. You don't need to add the `.PS1` extension. -- **XDG** variables +- `XDG` variables On non-Windows platforms, PowerShell uses the following XDG environment variables as defined by the [XDG Base Directory Specification][13]. - - **XDG_CONFIG_HOME** - - **XDG_DATA_HOME** - - **XDG_CACHE_HOME** + - `XDG_CONFIG_HOME` + - `XDG_DATA_HOME` + - `XDG_CACHE_HOME` ### Terminal features Beginning in PowerShell 7.2, the following environment variables can be used to control the Virtual Terminal features like ANSI escape sequences that colorize -output. Support for ANSI escape sequences can be turned off using the **TERM** -or **NO_COLOR** environment variables. +output. Support for ANSI escape sequences can be turned off using the `TERM` +or `NO_COLOR` environment variables. -- **TERM** +- `TERM` The following values of `$env:TERM` change the behavior as follows: @@ -543,10 +543,10 @@ or **NO_COLOR** environment variables. - `xterm-mono` - sets `$PSStyle.OutputRendering = PlainText` - `xtermm` - sets `$PSStyle.OutputRendering = PlainText` -- **NO_COLOR** +- `NO_COLOR` If `$env:NO_COLOR` exists, then `$PSStyle.OutputRendering` is set to - **PlainText**. For more information about the **NO_COLOR** environment + `PlainText`. For more information about the `NO_COLOR` environment variable, see [https://no-color.org/][12]. ## See also diff --git a/reference/7.4/Microsoft.PowerShell.Core/About/about_Path_Syntax.md b/reference/7.4/Microsoft.PowerShell.Core/About/about_Path_Syntax.md index 78bdb6e1fd37..f899e3d70f7d 100644 --- a/reference/7.4/Microsoft.PowerShell.Core/About/about_Path_Syntax.md +++ b/reference/7.4/Microsoft.PowerShell.Core/About/about_Path_Syntax.md @@ -1,7 +1,7 @@ --- description: Describes the full and relative path formats in PowerShell. Locale: en-US -ms.date: 09/16/2023 +ms.date: 09/05/2024 online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_path_syntax?view=powershell-7.4&WT.mc_id=ps-gethelp schema: 2.0.0 title: about_Path_Syntax @@ -18,9 +18,9 @@ uniquely identified by their path names. A path is a combination of the item name, the container and subcontainers in which the item is located, and the PowerShell drive through which the containers are accessed. -In PowerShell, pathnames can be one of two types: _fully qualified_ and +In PowerShell, path names can be one of two types: _fully qualified_ and _relative_. A fully qualified path consists of all elements that make up a -path. The following syntax shows the elements in a fully qualified path name: +path. The following syntax shows the elements in a fully qualified path: ```Syntax [::]:[\[\...]]\ @@ -115,11 +115,35 @@ first file (`C:\TechDocs\Jan\Results.txt`) and the path for the second file (`C:\TechDocs\Feb\Results.txt`) allow you to clearly distinguish between the two files. +## Support for the Win32 File namespace + +On Windows, the cmdlets that support the FileSystem provider also support the +paths that use the Win32 File namespace format. You can only use these paths +with the **LiteralPath** parameter of the cmdlets. + +Paths in Win32 File namespace are prefixed with `\\?\`. The prefix tells the +Windows APIs to disable all string parsing and send the string that follows +directly to the file system. For example, if the file system supports large +paths and file names, you can exceed the **MAX_PATH** limits that are otherwise +enforced by the Windows APIs. + +For more information, see _Win32 File Namespaces_ in +[Naming Files, Paths, and Namespaces][01]. + ## See also -- [about_Locations](about_Locations.md) -- [Convert-Path](xref:Microsoft.PowerShell.Management.Convert-Path) -- [Join-Path](xref:Microsoft.PowerShell.Management.Join-Path) -- [Resolve-Path](xref:Microsoft.PowerShell.Management.Resolve-Path) -- [Split-Path](xref:Microsoft.PowerShell.Management.Split-Path) -- [Test-Path](xref:Microsoft.PowerShell.Management.Test-Path) +- [about_Locations][02] +- [Convert-Path][03] +- [Join-Path][04] +- [Resolve-Path][05] +- [Split-Path][06] +- [Test-Path][07] + + +[01]: /windows/win32/fileio/naming-a-file#win32-file-namespaces +[02]: about_Locations.md +[03]: xref:Microsoft.PowerShell.Management.Convert-Path +[04]: xref:Microsoft.PowerShell.Management.Join-Path +[05]: xref:Microsoft.PowerShell.Management.Resolve-Path +[06]: xref:Microsoft.PowerShell.Management.Split-Path +[07]: xref:Microsoft.PowerShell.Management.Test-Path diff --git a/reference/7.5/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md b/reference/7.5/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md index 454c6b5b18f7..28d850ff4dfa 100644 --- a/reference/7.5/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md +++ b/reference/7.5/Microsoft.PowerShell.Core/About/about_Comment_Based_Help.md @@ -869,4 +869,4 @@ Displays information about PowerShell cmdlets and concepts. - [about_Functions](about_Functions.md) - [about_Functions_Advanced_Parameters](about_Functions_Advanced_Parameters.md) - [about_Scripts](about_Scripts.md) -- [How to Write Cmdlet Help](https://go.microsoft.com/fwlink/?LinkID=123415) +- [Writing Comment-Based Help Topics](/powershell/scripting/developer/help/writing-comment-based-help-topics) diff --git a/reference/7.5/Microsoft.PowerShell.Core/About/about_Environment_Variables.md b/reference/7.5/Microsoft.PowerShell.Core/About/about_Environment_Variables.md index fd5bff448177..778a6082cdc7 100644 --- a/reference/7.5/Microsoft.PowerShell.Core/About/about_Environment_Variables.md +++ b/reference/7.5/Microsoft.PowerShell.Core/About/about_Environment_Variables.md @@ -1,7 +1,7 @@ --- description: Describes how to access and manage environment variables in PowerShell. Locale: en-US -ms.date: 04/22/2024 +ms.date: 09/05/2024 online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_environment_variables?view=powershell-7.5&WT.mc_id=ps-gethelp schema: 2.0.0 title: about_Environment_Variables @@ -14,13 +14,13 @@ Describes how to access and manage environment variables in PowerShell. Environment variables store data that's used by the operating system and other programs. PowerShell creates the following environment variables: -- **POWERSHELL_TELEMETRY_OPTOUT** -- **POWERSHELL_DISTRIBUTION_CHANNEL** -- **POWERSHELL_UPDATECHECK** -- **PSExecutionPolicyPreference** -- **PSModulePath** -- **PSModuleAnalysisCachePath** -- **PSDisableModuleAnalysisCacheCleanup** +- `POWERSHELL_TELEMETRY_OPTOUT` +- `POWERSHELL_DISTRIBUTION_CHANNEL` +- `POWERSHELL_UPDATECHECK` +- `PSExecutionPolicyPreference` +- `PSModulePath` +- `PSModuleAnalysisCachePath` +- `PSDisableModuleAnalysisCacheCleanup` For full descriptions of these variables, see the [PowerShell environment variables][03] of this article. @@ -339,7 +339,7 @@ preference variables, see [about_Preference_Variables][06]. The environment variables that store preferences include: -- **POWERSHELL_TELEMETRY_OPTOUT** +- `POWERSHELL_TELEMETRY_OPTOUT` To opt-out of telemetry, set the environment variable to `true`, `yes`, or `1`. For more information, see [about_Telemetry][09]. @@ -348,7 +348,7 @@ The environment variables that store preferences include: starting the PowerShell process. See the previous sections for information about creating persistent environment variables. -- **POWERSHELL_DISTRIBUTION_CHANNEL** +- `POWERSHELL_DISTRIBUTION_CHANNEL` Beginning in PowerShell 7.2, this environment variable is set by the installer packages to record the method and source of installation for @@ -357,7 +357,7 @@ The environment variables that store preferences include: This information is included in the telemetry data sent to Microsoft. Users shouldn't change this value. -- **POWERSHELL_UPDATECHECK** +- `POWERSHELL_UPDATECHECK` The update notification behavior can be changed using the `POWERSHELL_UPDATECHECK` environment variable. For more information, see @@ -375,7 +375,7 @@ The environment variables that store preferences include: PowerShell process. See the previous sections for information about creating persistent environment variables. -- **PSExecutionPolicyPreference** +- `PSExecutionPolicyPreference` Stores the execution policy set for the current session. This environment variable exists only when you set an execution policy for a single session. @@ -393,7 +393,7 @@ The environment variables that store preferences include: This information only applies to the Windows platform. For more information, see [about_Execution_Policies][05]. -- **PSModulePath** +- `PSModulePath` The `$env:PSModulePath` environment variable contains a list of folder locations that are searched to find modules and resources. On Windows, the @@ -425,7 +425,7 @@ The environment variables that store preferences include: For more information, see [about_PSModulePath][08]. -- **PSModuleAnalysisCachePath** +- `PSModuleAnalysisCachePath` PowerShell provides control over the file that's used to cache data about modules and their cmdlets. The cache is read at startup while searching for a @@ -474,7 +474,7 @@ The environment variables that store preferences include: } ``` -- **PSDisableModuleAnalysisCacheCleanup** +- `PSDisableModuleAnalysisCacheCleanup` When writing out the module analysis cache, PowerShell checks for modules that no longer exist to avoid an unnecessarily large cache. Sometimes these @@ -491,7 +491,7 @@ The environment variables that store preferences include: ### Path information -- **PATH** +- `PATH` The `$env:PATH` environment variable contains a list of folder locations that the operating system searches for executable files. On Windows, the list of @@ -499,7 +499,7 @@ The environment variables that store preferences include: non-Windows platforms, the colon (`:`) separates the folder locations in the environment variable. -- **PATHEXT** +- `PATHEXT` The `$env:PATHEXT` variable contains a list of file extensions that Windows considers to be executable files. When a script file with one of the listed @@ -519,23 +519,23 @@ The environment variables that store preferences include: PowerShell scripts always start in the current console session. You don't need to add the `.PS1` extension. -- **XDG** variables +- `XDG` variables On non-Windows platforms, PowerShell uses the following XDG environment variables as defined by the [XDG Base Directory Specification][13]. - - **XDG_CONFIG_HOME** - - **XDG_DATA_HOME** - - **XDG_CACHE_HOME** + - `XDG_CONFIG_HOME` + - `XDG_DATA_HOME` + - `XDG_CACHE_HOME` ### Terminal features Beginning in PowerShell 7.2, the following environment variables can be used to control the Virtual Terminal features like ANSI escape sequences that colorize -output. Support for ANSI escape sequences can be turned off using the **TERM** -or **NO_COLOR** environment variables. +output. Support for ANSI escape sequences can be turned off using the `TERM` +or `NO_COLOR` environment variables. -- **TERM** +- `TERM` The following values of `$env:TERM` change the behavior as follows: @@ -543,10 +543,10 @@ or **NO_COLOR** environment variables. - `xterm-mono` - sets `$PSStyle.OutputRendering = PlainText` - `xtermm` - sets `$PSStyle.OutputRendering = PlainText` -- **NO_COLOR** +- `NO_COLOR` If `$env:NO_COLOR` exists, then `$PSStyle.OutputRendering` is set to - **PlainText**. For more information about the **NO_COLOR** environment + `PlainText`. For more information about the `NO_COLOR` environment variable, see [https://no-color.org/][12]. ## See also diff --git a/reference/7.5/Microsoft.PowerShell.Core/About/about_Path_Syntax.md b/reference/7.5/Microsoft.PowerShell.Core/About/about_Path_Syntax.md index 92b81b91773b..3e37e324b1a0 100644 --- a/reference/7.5/Microsoft.PowerShell.Core/About/about_Path_Syntax.md +++ b/reference/7.5/Microsoft.PowerShell.Core/About/about_Path_Syntax.md @@ -1,7 +1,7 @@ --- description: Describes the full and relative path formats in PowerShell. Locale: en-US -ms.date: 09/16/2023 +ms.date: 09/05/2024 online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_path_syntax?view=powershell-7.5&WT.mc_id=ps-gethelp schema: 2.0.0 title: about_Path_Syntax @@ -18,9 +18,9 @@ uniquely identified by their path names. A path is a combination of the item name, the container and subcontainers in which the item is located, and the PowerShell drive through which the containers are accessed. -In PowerShell, pathnames can be one of two types: _fully qualified_ and +In PowerShell, path names can be one of two types: _fully qualified_ and _relative_. A fully qualified path consists of all elements that make up a -path. The following syntax shows the elements in a fully qualified path name: +path. The following syntax shows the elements in a fully qualified path: ```Syntax [::]:[\[\...]]\ @@ -115,11 +115,35 @@ first file (`C:\TechDocs\Jan\Results.txt`) and the path for the second file (`C:\TechDocs\Feb\Results.txt`) allow you to clearly distinguish between the two files. +## Support for the Win32 File namespace + +On Windows, the cmdlets that support the FileSystem provider also support the +paths that use the Win32 File namespace format. You can only use these paths +with the **LiteralPath** parameter of the cmdlets. + +Paths in Win32 File namespace are prefixed with `\\?\`. The prefix tells the +Windows APIs to disable all string parsing and send the string that follows +directly to the file system. For example, if the file system supports large +paths and file names, you can exceed the **MAX_PATH** limits that are otherwise +enforced by the Windows APIs. + +For more information, see _Win32 File Namespaces_ in +[Naming Files, Paths, and Namespaces][01]. + ## See also -- [about_Locations](about_Locations.md) -- [Convert-Path](xref:Microsoft.PowerShell.Management.Convert-Path) -- [Join-Path](xref:Microsoft.PowerShell.Management.Join-Path) -- [Resolve-Path](xref:Microsoft.PowerShell.Management.Resolve-Path) -- [Split-Path](xref:Microsoft.PowerShell.Management.Split-Path) -- [Test-Path](xref:Microsoft.PowerShell.Management.Test-Path) +- [about_Locations][02] +- [Convert-Path][03] +- [Join-Path][04] +- [Resolve-Path][05] +- [Split-Path][06] +- [Test-Path][07] + + +[01]: /windows/win32/fileio/naming-a-file#win32-file-namespaces +[02]: about_Locations.md +[03]: xref:Microsoft.PowerShell.Management.Convert-Path +[04]: xref:Microsoft.PowerShell.Management.Join-Path +[05]: xref:Microsoft.PowerShell.Management.Resolve-Path +[06]: xref:Microsoft.PowerShell.Management.Split-Path +[07]: xref:Microsoft.PowerShell.Management.Test-Path diff --git a/reference/docs-conceptual/community/2024-updates.md b/reference/docs-conceptual/community/2024-updates.md index 4c94606f190f..fa67906852b1 100644 --- a/reference/docs-conceptual/community/2024-updates.md +++ b/reference/docs-conceptual/community/2024-updates.md @@ -1,6 +1,6 @@ --- description: List of changes to the PowerShell documentation for 2024 -ms.date: 08/05/2024 +ms.date: 09/05/2024 title: What's New in PowerShell-Docs for 2024 --- # What's new in PowerShell Docs for 2024 @@ -11,6 +11,30 @@ community. Help us make the documentation better for you. Read the [Contributor's Guide][01] to learn how to get started. +## 2024-August + +- Updates for new releases of PowerShell 7.2.23, 7.4.5 and 7.5-preview.4 +- Two new cmdlets in 7.5-preview.4 + - [ConvertFrom-CliXml](xref:Microsoft.PowerShell.Utility.ConvertFrom-CliXml) + - [ConvertTo-CliXml](xref:Microsoft.PowerShell.Utility.ConvertTo-CliXml) + +### Top Community Contributors + +GitHub stats + +- 25 PRs merged (4 from Community) +- 20 issues opened (18 from Community) +- 20 issues closed (17 Community issues closed) + +The following people contributed to PowerShell docs this month by submitting pull requests or +filing issues. Thank you! + +| GitHub Id | PRs merged | Issues opened | +| ------------------ | :--------: | :-----------: | +| RokeJulianLockhart | 1 | | +| mohitNarang | 1 | | +| aberus | 1 | | + ## 2024-July - Updates for new releases of PowerShell 7.2.22 and 7.4.4 diff --git a/reference/docs-conceptual/community/contributing/product-terminology.md b/reference/docs-conceptual/community/contributing/product-terminology.md index 92cad1199f64..8b0fa60ecadf 100644 --- a/reference/docs-conceptual/community/contributing/product-terminology.md +++ b/reference/docs-conceptual/community/contributing/product-terminology.md @@ -84,17 +84,20 @@ The earliest collection of modules for managing legacy Azure resources that use Manager (ASM) APIs. This legacy PowerShell module isn't recommended when creating new resources since ASM is scheduled for retirement. -### Azure PowerShell-related products +### Azure-related PowerShell modules These products are used to manage Azure resources but aren't part of the Azure PowerShell collective product. They should never be described using the "Azure PowerShell" collective name. -- Azure Active Directory PowerShell +- Azure Active Directory PowerShell (AzureAD) - Azure Information Protection PowerShell - Azure Deployment Manager PowerShell - Azure Elastic Database Jobs PowerShell - Azure Service Fabric PowerShell - Azure Stack PowerShell +- Microsoft.Graph PowerShell +- Microsoft.Graph.Entra PowerShell +- MSOnline PowerShell Guidelines diff --git a/reference/docs-conceptual/community/hall-of-fame.md b/reference/docs-conceptual/community/hall-of-fame.md index 86bd95d6acd3..1d5085cc4a91 100644 --- a/reference/docs-conceptual/community/hall-of-fame.md +++ b/reference/docs-conceptual/community/hall-of-fame.md @@ -1,6 +1,6 @@ --- description: List of the GitHub users that have the most contributions to the PowerShell-Doc project. -ms.date: 08/05/2024 +ms.date: 09/05/2024 title: Community contributor Hall of Fame --- # Community Contributor Hall of Fame @@ -17,7 +17,7 @@ Pull Requests help us fix those issues and make the documentation better for eve | PRs Merged | 2015 | 2016 | 2017 | 2018 | 2019 | 2020 | 2021 | 2022 | 2023 | 2024 | Grand Total | | --------------- | ---: | ---: | ---: | ---: | ---: | ---: | ---: | ---: | ---: | ---: | ----------: | -| Community | 3 | 194 | 446 | 464 | 318 | 161 | 100 | 122 | 108 | 49 | 1965 | +| Community | 3 | 194 | 446 | 464 | 318 | 161 | 100 | 122 | 108 | 53 | 1969 | | matt9ucci | | | 157 | 80 | 30 | 1 | 6 | | | | 274 | | nschonni | | | | 14 | 138 | 10 | | | | | 162 | | kiazhi | | 25 | 79 | 12 | | | | | | | 116 | @@ -45,15 +45,15 @@ GitHub issues help us identify errors and gaps in our documentation. | Issues Opened | 2015 | 2016 | 2017 | 2018 | 2019 | 2020 | 2021 | 2022 | 2023 | 2024 | Grand Total | | --------------- | ---: | ---: | ---: | ---: | ---: | ---: | ---: | ---: | ---: | ---: | ----------: | -| Community | 3 | 54 | 95 | 211 | 561 | 557 | 365 | 225 | 269 | 139 | 2479 | -| mklement0 | | | 19 | 60 | 56 | 61 | 28 | 8 | 20 | 22 | 274 | +| Community | 3 | 54 | 95 | 211 | 561 | 557 | 365 | 225 | 270 | 157 | 2498 | +| mklement0 | | | 19 | 60 | 56 | 61 | 28 | 8 | 20 | 23 | 275 | | ehmiiz | | | | | | | | 20 | 14 | | 34 | | iSazonov | | | 1 | 4 | 10 | 8 | 4 | 3 | | 1 | 31 | | jszabo98 | | | | 2 | 15 | 6 | 1 | | 1 | 2 | 27 | | juvtib | | | | | | 15 | 7 | | | | 22 | | doctordns | | | 5 | 3 | 5 | 7 | 1 | | | | 21 | | peetrike | | | | 1 | | 4 | 2 | 6 | 4 | 3 | 20 | -| iRon7 | | | | | | 2 | 2 | 2 | 10 | 2 | 18 | +| iRon7 | | | | | | 2 | 2 | 2 | 10 | 4 | 20 | | vexx32 | | | | 3 | 11 | | | 3 | | | 17 | | JustinGrote | | | | 1 | 3 | 6 | 1 | 1 | 2 | 2 | 16 | | KirkMunro | | | | 7 | 7 | 1 | | | | | 15 |