Skip to content

Clarify that the stop-parsing symbol is near-useless on Unix-like platforms (about_parsing) #4963

Closed

Description

Documentation Issue

While --%, the stop-parsing symbol technically works on Unix-like platforms (macOS, Linux), its Windows-focused behavior makes it near-useless there, which should be clearly stated.

Context of the issue

  • URL to the article (Docs or GitHub URL): https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_parsing

  • Issue affects the following content (check all that apply):

    Cmdlet reference & about_ topics

    • Version 7 content
    • Version 6 content
    • Version 5.1 content
    • Version 5.0 content
    • Version 4.0 content
    • Version 3.0 content

    Conceptual articles

    • Fundamental conceptual articles
    • Script sample articles
    • DSC articles
    • Gallery articles
    • JEA articles
    • WMF articles
    • SDK articles
  • Is the issue specific to a platform (Y/N - Win/macOS/Linux): N

Detailed description of the issue

The idea behind --% was to allow command lines designed for cmd.exe to work in PowerShell.

The generalization of this idea would be to make --% work similar to /bin/sh (the default, POSIX-like shell) on Unix-like platforms; however, in PowerShell/PowerShell#3733 it was decided not to attempt that, so --%' s behavior remains Windows-focused.

As such, it has little value on Unix-like platforms, and that should be noted in about_Parsing.

Specifically, the following aspects make the behavior a poor fit on Unix:

Activity

  1. added a commit that references this issue on Mar 30, 2020
    fb13c88
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

area-languageArea - PowerShell syntax and keywords

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions