Skip to content

Support excluding some files from formatting #4482

@annagrin

Description

@annagrin

Describe the bug
Setting dart.doNotFormat does not seem to work.

To Reproduce
Steps to reproduce the behavior:

  1. Add the following lines to settings.json
"dart.doNotFormat": [
        "**/fixtures/**",
        "**/flutter/flutter/**"
    ],
    "editor.defaultFormatter": "Dart-Code.dart-code",
    "editor.formatOnSave": true,

Expected behavior
Code does not get formatted on save in files /User/<name>/source/webdev/fixtures

Please complete the following information:

  • Operating System and version: MacOS 13.2.1, Apple M1 Max
  • VS Code version: Version: 1.76.2 (Universal)
  • Dart extension version: v3.62.0
  • Dart/Flutter SDK version: Flutter (Channel unknown, 3.9.0-20.0.pre.33, on macOS 13.2.1 22D68 darwin-arm64, locale en-US)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions