diff --git a/reference/5.1/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md b/reference/5.1/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md index 91449c0bcaf4..951e1613bb53 100644 --- a/reference/5.1/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md +++ b/reference/5.1/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md @@ -1,7 +1,7 @@ --- description: Describes rules for using single and double quotation marks in PowerShell. Locale: en-US -ms.date: 03/20/2024 +ms.date: 09/04/2024 online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_quoting_rules?view=powershell-5.1&WT.mc_id=ps-gethelp schema: 2.0.0 title: about_Quoting_Rules @@ -13,6 +13,13 @@ Describes rules for using single and double quotation marks in PowerShell. ## Long description +When parsing, PowerShell first looks to interpret input as an expression. But +when a command invocation is encountered, parsing continues in argument mode. +Non-numeric arguments without quotes are treated as strings. If you have +arguments that contain spaces, such as paths, then you must enclose those +argument values in quotes. For more information about argument parsing, see the +**Argument mode** section of [about_Parsing][01]. + Quotation marks are used to specify a literal string. You can enclose a string in single quotation marks (`'`) or double quotation marks (`"`). @@ -427,12 +434,11 @@ For more information about this behavior, see the [about_Parsing][02] article. ## See also -- [about_Parsing][01] - [about_Special_Characters][04] - [ConvertFrom-StringData][05] -[01]: about_Parsing.md +[01]: about_Parsing.md#argument-mode [02]: about_Parsing.md#passing-arguments-that-contain-quote-characters [03]: about_preference_variables.md#ofs [04]: about_Special_Characters.md diff --git a/reference/7.2/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md b/reference/7.2/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md index d557050cd04f..c4a93263182a 100644 --- a/reference/7.2/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md +++ b/reference/7.2/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md @@ -1,7 +1,7 @@ --- description: Describes rules for using single and double quotation marks in PowerShell. Locale: en-US -ms.date: 03/20/2024 +ms.date: 09/04/2024 online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_quoting_rules?view=powershell-7.2&WT.mc_id=ps-gethelp schema: 2.0.0 title: about_Quoting_Rules @@ -13,6 +13,13 @@ Describes rules for using single and double quotation marks in PowerShell. ## Long description +When parsing, PowerShell first looks to interpret input as an expression. But +when a command invocation is encountered, parsing continues in argument mode. +Non-numeric arguments without quotes are treated as strings. If you have +arguments that contain spaces, such as paths, then you must enclose those +argument values in quotes. For more information about argument parsing, see the +**Argument mode** section of [about_Parsing][01]. + Quotation marks are used to specify a literal string. You can enclose a string in single quotation marks (`'`) or double quotation marks (`"`). @@ -427,12 +434,11 @@ For more information about this behavior, see the [about_Parsing][02] article. ## See also -- [about_Parsing][01] - [about_Special_Characters][04] - [ConvertFrom-StringData][05] -[01]: about_Parsing.md +[01]: about_Parsing.md#argument-mode [02]: about_Parsing.md#passing-arguments-that-contain-quote-characters [03]: about_preference_variables.md#ofs [04]: about_Special_Characters.md diff --git a/reference/7.4/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md b/reference/7.4/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md index 2e55e21378a2..507d82c437ee 100644 --- a/reference/7.4/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md +++ b/reference/7.4/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md @@ -1,7 +1,7 @@ --- description: Describes rules for using single and double quotation marks in PowerShell. Locale: en-US -ms.date: 03/20/2024 +ms.date: 09/04/2024 online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_quoting_rules?view=powershell-7.4&WT.mc_id=ps-gethelp schema: 2.0.0 title: about_Quoting_Rules @@ -13,6 +13,13 @@ Describes rules for using single and double quotation marks in PowerShell. ## Long description +When parsing, PowerShell first looks to interpret input as an expression. But +when a command invocation is encountered, parsing continues in argument mode. +Non-numeric arguments without quotes are treated as strings. If you have +arguments that contain spaces, such as paths, then you must enclose those +argument values in quotes. For more information about argument parsing, see the +**Argument mode** section of [about_Parsing][01]. + Quotation marks are used to specify a literal string. You can enclose a string in single quotation marks (`'`) or double quotation marks (`"`). @@ -427,12 +434,11 @@ For more information about this behavior, see the [about_Parsing][02] article. ## See also -- [about_Parsing][01] - [about_Special_Characters][04] - [ConvertFrom-StringData][05] -[01]: about_Parsing.md +[01]: about_Parsing.md#argument-mode [02]: about_Parsing.md#passing-arguments-that-contain-quote-characters [03]: about_preference_variables.md#ofs [04]: about_Special_Characters.md diff --git a/reference/7.5/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md b/reference/7.5/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md index 96b2807c6ec8..5ff5c0440b61 100644 --- a/reference/7.5/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md +++ b/reference/7.5/Microsoft.PowerShell.Core/About/about_Quoting_Rules.md @@ -1,7 +1,7 @@ --- description: Describes rules for using single and double quotation marks in PowerShell. Locale: en-US -ms.date: 03/20/2024 +ms.date: 09/04/2024 online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_quoting_rules?view=powershell-7.5&WT.mc_id=ps-gethelp schema: 2.0.0 title: about_Quoting_Rules @@ -13,6 +13,13 @@ Describes rules for using single and double quotation marks in PowerShell. ## Long description +When parsing, PowerShell first looks to interpret input as an expression. But +when a command invocation is encountered, parsing continues in argument mode. +Non-numeric arguments without quotes are treated as strings. If you have +arguments that contain spaces, such as paths, then you must enclose those +argument values in quotes. For more information about argument parsing, see the +**Argument mode** section of [about_Parsing][01]. + Quotation marks are used to specify a literal string. You can enclose a string in single quotation marks (`'`) or double quotation marks (`"`). @@ -427,12 +434,11 @@ For more information about this behavior, see the [about_Parsing][02] article. ## See also -- [about_Parsing][01] - [about_Special_Characters][04] - [ConvertFrom-StringData][05] -[01]: about_Parsing.md +[01]: about_Parsing.md#argument-mode [02]: about_Parsing.md#passing-arguments-that-contain-quote-characters [03]: about_preference_variables.md#ofs [04]: about_Special_Characters.md