Skip to content

Copilot appears to ignore instructions when applyTo uses a file-specific glob pattern #293592

@starlight173

Description

@starlight173
  • Copilot Chat Extension Version: 0.37.1
  • VS Code Version: 1.109.0
  • OS Version: Windows
  • Feature : Agent mode
  • Selected model: Claude 4.5 Sonnet
  • Logs: N/A (no errors logged)

Steps to Reproduce:

  1. Create a Copilot instructions file at:
    .github/instructions/bloc.instructions.md

  2. Add the following content:

   applyTo: "**/*.dart"
Always use Bloc instead of Cubit.
Never suggest GlobalKey unless absolutely required.
  1. Open any .dart file in VS Code.

  2. Use GitHub Copilot Chat to generate or edit code.

  3. Observe that Copilot does not follow the instructions.

  4. Change the instructions file to:

    applyTo: "**"
  5. Repeat step 4.

  6. Observe that Copilot does follow the instructions when applyTo is set to "**".

Expected Result:
Copilot should apply instructions when applyTo matches the current file (**/*.dart).

Actual Result:
Copilot appears to ignore instructions when applyTo uses a file-specific glob pattern, but works when using the global pattern "**".

Metadata

Metadata

Labels

info-neededIssue requires more information from poster

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions