@@ -199,10 +199,12 @@ class AnalysisServer {
199
199
}
200
200
201
201
Future <EditBulkFixesResult > requestBulkFixes (
202
- String filePath, bool inTestMode, List <String > codes) {
202
+ String filePath, bool inTestMode, List <String > codes,
203
+ {bool updatePubspec = false }) {
203
204
return _sendCommand ('edit.bulkFixes' , params: < String , dynamic > {
204
205
'included' : [path.canonicalize (filePath)],
205
206
'inTestMode' : inTestMode,
207
+ 'updatePubspec' : updatePubspec,
206
208
if (codes.isNotEmpty) 'codes' : codes,
207
209
}).then ((result) {
208
210
return EditBulkFixesResult .fromJson (
@@ -212,13 +214,18 @@ class AnalysisServer {
212
214
213
215
Future <void > shutdown ({Duration ? timeout}) async {
214
216
// Request shutdown.
215
- final Future <void > future = _sendCommand ('server.shutdown' ).then ((Map <String , dynamic > value) {
217
+ final Future <void > future =
218
+ _sendCommand ('server.shutdown' ).then ((Map <String , dynamic > value) {
216
219
_shutdownResponseReceived = true ;
217
220
return ;
218
221
});
219
- await (timeout != null ? future.timeout (timeout, onTimeout: () {
220
- log.stderr ('The analysis server timed out while shutting down.' );
221
- }) : future).whenComplete (dispose);
222
+ await (timeout != null
223
+ ? future.timeout (timeout, onTimeout: () {
224
+ log.stderr (
225
+ 'The analysis server timed out while shutting down.' );
226
+ })
227
+ : future)
228
+ .whenComplete (dispose);
222
229
}
223
230
224
231
/// Send an `analysis.updateContent` request with the given [files] .
0 commit comments