MCPcopy Create free account
hub / github.com/Dart-Code/Dart-Code / flutterUpgrade

Method flutterUpgrade

src/extension/commands/flutter.ts:162–174  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

160 }
161
162 private async flutterUpgrade() {
163 if (!this.workspace.sdks.flutter) {
164 this.sdkUtils.showFlutterActivationFailure("flutter.upgrade");
165 return;
166 }
167 const tempDir = path.join(os.tmpdir(), "dart-code-cmd-run");
168 if (!fs.existsSync(tempDir))
169 fs.mkdirSync(tempDir);
170 // Don't prompt to reload when the version changes, as we automatically reload here.
171 commandState.promptToReloadOnVersionChanges = false;
172 await this.runFlutterInFolder(tempDir, ["upgrade"], "flutter", true);
173 await util.promptToReloadExtension(this.logger, { restartReason: ExtensionRestartReason.AfterFlutterUpgrade });
174 }
175
176 private async flutterCreate({ packageName, packagePath, triggerData, platform }: FlutterCreateCommandArgs) {
177 if (!packagePath) {

Callers

nothing calls this directly

Calls 2

runFlutterInFolderMethod · 0.65

Tested by

no test coverage detected