-
Notifications
You must be signed in to change notification settings - Fork 344
Closed
Labels
in flutterRelates to running Flutter appsRelates to running Flutter appsis enhancementAn enhancement or improvement that should be listed in release notes but is not a bug fix.An enhancement or improvement that should be listed in release notes but is not a bug fix.
Milestone
Description
This code does a basic regex to check for sdk: flutter in the pubspec.yaml to decide whether a project is a Flutter project or not:
Dart-Code/src/shared/utils/fs.ts
Lines 141 to 144 in b7c1124
| export function pubspecContentReferencesFlutterSdk(content: string): boolean { | |
| const regex = new RegExp("sdk\\s*:\\s*[\"']?flutter[\"']?", "i"); | |
| return regex.test(content); | |
| } |
It was done this way for simplicity when we had no yaml parser referenced. It can be tripped up by comments and other unrelated keys. Now we have a yaml parser, we should do this properly so it's reliable.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
in flutterRelates to running Flutter appsRelates to running Flutter appsis enhancementAn enhancement or improvement that should be listed in release notes but is not a bug fix.An enhancement or improvement that should be listed in release notes but is not a bug fix.