Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(128)

Side by Side Diff: sdk/lib/_internal/pub/lib/src/command/uploader.dart

Issue 18143002: Reorganize some pub libraries. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Remove some newlines. Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library command_uploader; 5 library pub.command.uploader;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 import 'dart:io'; 8 import 'dart:io';
9 9
10 import 'package:args/args.dart'; 10 import 'package:args/args.dart';
11 import 'package:pathos/path.dart' as path; 11 import 'package:pathos/path.dart' as path;
12 12
13 import 'command.dart'; 13 import '../command.dart';
14 import 'entrypoint.dart'; 14 import '../entrypoint.dart';
15 import 'exit_codes.dart' as exit_codes; 15 import '../exit_codes.dart' as exit_codes;
16 import 'http.dart'; 16 import '../http.dart';
17 import 'hosted_source.dart'; 17 import '../io.dart';
18 import 'io.dart'; 18 import '../log.dart' as log;
19 import 'log.dart' as log; 19 import '../oauth2.dart' as oauth2;
20 import 'oauth2.dart' as oauth2; 20 import '../source/hosted.dart';
21 import 'utils.dart'; 21 import '../utils.dart';
22 22
23 /// Handles the `uploader` pub command. 23 /// Handles the `uploader` pub command.
24 class UploaderCommand extends PubCommand { 24 class UploaderCommand extends PubCommand {
25 final description = "Manage uploaders for a package on pub.dartlang.org."; 25 final description = "Manage uploaders for a package on pub.dartlang.org.";
26 final usage = "pub uploader [options] {add/remove} <email>"; 26 final usage = "pub uploader [options] {add/remove} <email>";
27 final requiresEntrypoint = false; 27 final requiresEntrypoint = false;
28 28
29 /// The URL of the package hosting server. 29 /// The URL of the package hosting server.
30 Uri get server => Uri.parse(commandOptions['server']); 30 Uri get server => Uri.parse(commandOptions['server']);
31 31
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 "${Uri.encodeComponent(package)}/uploaders/" 73 "${Uri.encodeComponent(package)}/uploaders/"
74 "${Uri.encodeComponent(uploader)}"); 74 "${Uri.encodeComponent(uploader)}");
75 return client.delete(url, headers: PUB_API_HEADERS); 75 return client.delete(url, headers: PUB_API_HEADERS);
76 } 76 }
77 }); 77 });
78 }).then(handleJsonSuccess) 78 }).then(handleJsonSuccess)
79 .catchError((error) => handleJsonError(error.response), 79 .catchError((error) => handleJsonError(error.response),
80 test: (e) => e is PubHttpException); 80 test: (e) => e is PubHttpException);
81 } 81 }
82 } 82 }
OLDNEW
« no previous file with comments | « sdk/lib/_internal/pub/lib/src/command/update.dart ('k') | sdk/lib/_internal/pub/lib/src/command/version.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698