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

Issue 9950005: First check in for pub package manager. (Closed)

Created:
8 years, 8 months ago by Bob Nystrom
Modified:
8 years, 8 months ago
Reviewers:
nweiz, kasperl
CC:
reviews_dartlang.org, kasperl
Visibility:
Public.

Description

First check in for pub package manager. It doesn't do anything more than show usage and version, but the test infrastructure is there. Committed: https://code.google.com/p/dart/source/detail?r=6066

Patch Set 1 #

Total comments: 13

Patch Set 2 : Respond to awesome review. #

Patch Set 3 : Rebase. #

Total comments: 4

Patch Set 4 : Respond to review. #

Total comments: 6
Unified diffs Side-by-side diffs Delta from patch set Stats (+290 lines, -3 lines) Patch
M tools/testing/dart/test_suite.dart View 1 2 3 1 chunk +46 lines, -0 lines 0 comments Download
A utils/pub/pub.dart View 1 1 chunk +85 lines, -0 lines 4 comments Download
A utils/pub/utils.dart View 1 chunk +21 lines, -0 lines 0 comments Download
M utils/tests/pub/pub_tests.dart View 1 1 chunk +32 lines, -3 lines 0 comments Download
A utils/tests/pub/test_pub.dart View 1 2 3 1 chunk +106 lines, -0 lines 2 comments Download

Messages

Total messages: 6 (0 generated)
Bob Nystrom
This is more or less a "shell" patch. Pub doesn't do anything interesting yet, but ...
8 years, 8 months ago (2012-03-29 23:47:15 UTC) #1
nweiz
https://chromiumcodereview.appspot.com/9950005/diff/1/tools/testing/dart/test_suite.dart File tools/testing/dart/test_suite.dart (right): https://chromiumcodereview.appspot.com/9950005/diff/1/tools/testing/dart/test_suite.dart#newcode988 tools/testing/dart/test_suite.dart:988: * A standard test suite whose file organization matches ...
8 years, 8 months ago (2012-03-30 00:38:37 UTC) #2
Bob Nystrom
Thanks! https://chromiumcodereview.appspot.com/9950005/diff/1/tools/testing/dart/test_suite.dart File tools/testing/dart/test_suite.dart (right): https://chromiumcodereview.appspot.com/9950005/diff/1/tools/testing/dart/test_suite.dart#newcode988 tools/testing/dart/test_suite.dart:988: * A standard test suite whose file organization ...
8 years, 8 months ago (2012-03-30 01:06:17 UTC) #3
nweiz
lgtm https://chromiumcodereview.appspot.com/9950005/diff/8001/utils/tests/pub/test_pub.dart File utils/tests/pub/test_pub.dart (right): https://chromiumcodereview.appspot.com/9950005/diff/8001/utils/tests/pub/test_pub.dart#newcode71 utils/tests/pub/test_pub.dart:71: * leading and trailing whitespaces differences and tries ...
8 years, 8 months ago (2012-03-30 01:25:06 UTC) #4
kasperl
LGTM. Nits: https://chromiumcodereview.appspot.com/9950005/diff/5007/utils/pub/pub.dart File utils/pub/pub.dart (right): https://chromiumcodereview.appspot.com/9950005/diff/5007/utils/pub/pub.dart#newcode34 utils/pub/pub.dart:34: exit(64); // see http://www.freebsd.org/cgi/man.cgi?query=sysexits. see -> See ...
8 years, 8 months ago (2012-04-11 07:17:03 UTC) #5
Bob Nystrom
8 years, 8 months ago (2012-04-11 16:50:22 UTC) #6
Thanks!

https://chromiumcodereview.appspot.com/9950005/diff/8001/utils/tests/pub/test...
File utils/tests/pub/test_pub.dart (right):

https://chromiumcodereview.appspot.com/9950005/diff/8001/utils/tests/pub/test...
utils/tests/pub/test_pub.dart:71: * leading and trailing whitespaces differences
and tries to report the
On 2012/03/30 01:25:06, nweiz wrote:
> s/whitespaces/whitespace/

Done.

https://chromiumcodereview.appspot.com/9950005/diff/8001/utils/tests/pub/test...
utils/tests/pub/test_pub.dart:80: Expect.fail('Output line ${i + 1} was:
${actual[i]}\nexpected: ${expected[i]}');
On 2012/03/30 01:25:06, nweiz wrote:
> Line length; use """?

Done. ''' actually wouldn't work here because then you'd get the newline in your
string. Fortunately, in this case, the whole string fits on one line if you move
it down.

https://chromiumcodereview.appspot.com/9950005/diff/5007/utils/pub/pub.dart
File utils/pub/pub.dart (right):

https://chromiumcodereview.appspot.com/9950005/diff/5007/utils/pub/pub.dart#n...
utils/pub/pub.dart:34: exit(64); // see
http://www.freebsd.org/cgi/man.cgi?query=sysexits.
On 2012/04/11 07:17:03, kasperl wrote:
> see -> See

Done (in a forthcoming patch).

https://chromiumcodereview.appspot.com/9950005/diff/5007/utils/pub/pub.dart#n...
utils/pub/pub.dart:44: print('Pub is a package manager for Dart.');
On 2012/04/11 07:17:03, kasperl wrote:
> Wouldn't this be nicer in a multiline string constant somewhere?

I did that at first, but the problem is multiline strings don't handle
indentation well. I don't want to have to break the indentation of the file for
the string, so this seemed like the cleanest solution.

https://chromiumcodereview.appspot.com/9950005/diff/5007/utils/tests/pub/test...
File utils/tests/pub/test_pub.dart (right):

https://chromiumcodereview.appspot.com/9950005/diff/5007/utils/tests/pub/test...
utils/tests/pub/test_pub.dart:26: '../../../tools/testing/bin/$platform/dart');
On 2012/04/11 07:17:03, kasperl wrote:
> You sometimes indent these with 4 spaces and sometimes 2.

Normal indentation should be 2 spaces, and line continuations should be 4 (or
more, to align with stuff). I think that's more or less Google standard style,
though you're right that there are probably mistakes where I'm not following it
right.

Powered by Google App Engine
This is Rietveld 408576698