Skip to content

VSCode GitHub Copilot chat errors on .claude/settings copy.jsonΒ #1616

@marioja

Description

@marioja

Problem

When VSCode's GitHub Copilot chat is active and the workspace contains .claude/settings copy.json, Copilot picks it up as an active Claude Code settings file and tries to execute the hooks it defines. The hook commands fail under Windows PowerShell with:

The token '||' is not a valid statement separator in this version.

This fires repeatedly on SessionStart, UserPromptSubmit, and Stop hook events inside VSCode. It surfaces as a noisy error in Copilot chat panels and effectively breaks the hook pipeline for anyone who has Copilot chat running alongside claude-flow.

Root cause

The file .claude/settings copy.json has a .json extension, so Copilot's workspace scanner treats it as a valid Claude Code settings file and attempts to run the hooks. The PowerShell-incompatible || operator in the hook commands then fails.

Fix

Rename the file so the .json extension is no longer the final extension, which prevents Copilot from treating it as a live settings file:

.claude/settings copy.json  β†’  .claude/settings.json.copy

PR

See #1615 for the proposed rename.

Feel free to ignore the PR if you prefer to fix this yourself β€” it's just a file rename with no content changes, no functional impact on claude-flow itself.

Environment

  • OS: Windows 11
  • Shell: PowerShell (the one Copilot spawns, not the bash shell Claude Code uses)
  • VSCode with GitHub Copilot chat enabled

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions