Skip to content

Add host-selected PowerShell dialect analysis - #139

Merged
Aaronontheweb merged 10 commits into
devfrom
design/v03-host-grammar-boundary
Aug 10, 2026
Merged

Add host-selected PowerShell dialect analysis#139
Aaronontheweb merged 10 commits into
devfrom
design/v03-host-grammar-boundary

Conversation

@Aaronontheweb

Copy link
Copy Markdown
Owner

Outcome

Adds the host-selected grammar boundary and explicit PowerShell dialect contract required for native Windows execution without cross-language parsing.

  • keeps Bash and PowerShell as separate top-level grammars
  • adds the compatible PowerShell7 default and explicit WindowsPowerShell51 fallback
  • bounds the PowerShell 7 metadata contract to >=7.6.4 and <7.7
  • rejects PowerShell 7 pipeline chains throughout every nested Windows PowerShell 5.1 parse path
  • uses dialect-local aliases, receiver metadata, persistent state, and static child-host selection
  • routes generated corpus and live oracle validation through the selected executable
  • verifies powershell.exe from the same Bash PATH used by dotnet test on Windows CI
  • documents executor, parser, approval-policy, and model-context identity requirements

Compatibility and security

The public API diff against published 0.3.0-alpha.4 contains exactly two additive changes on both net8.0 and netstandard2.0: PwshDialect and one PwshParserOptions property. Unknown dialects, unsupported 5.1 syntax, ambiguous receivers, and unavailable metadata remain fail closed. Cross-language payloads remain ordinary arguments.

Validation

  • dotnet build -c Release: clean, zero warnings
  • dotnet test -c Release --no-build: 2,813 passed
  • focused dialect, catalog, corpus, and live-oracle suite: 963 passed
  • generated PowerShell corpus: exact 503-file match
  • pwsh ./scripts/Add-FileHeaders.ps1 -Verify: passed
  • dotnet pack -c Release --no-build: passed
  • openspec validate v0-3-structured-shell-analysis --strict: passed
  • Slopwatch strict full-tree scan: 0 findings
  • adversarial review: PASS, no remaining findings

Auto-merge will be enabled after the first Windows run proves the Windows PowerShell 5.1 oracle gate.

@Aaronontheweb
Aaronontheweb enabled auto-merge (squash) August 10, 2026 05:01
@Aaronontheweb
Aaronontheweb merged commit 45416f0 into dev Aug 10, 2026
2 checks passed
@Aaronontheweb
Aaronontheweb deleted the design/v03-host-grammar-boundary branch August 10, 2026 05:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant