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

Issue 341123002: Support running executables from dependencies. (Closed)

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

Description

Support running executables from dependencies. BUG=https://code.google.com/p/dart/issues/detail?id=18537 R=nweiz@google.com Committed: https://code.google.com/p/dart/source/detail?r=37561

Patch Set 1 #

Total comments: 13

Patch Set 2 : Revise. #

Total comments: 6

Messages

Total messages: 7 (0 generated)
Bob Nystrom
6 years, 6 months ago (2014-06-19 18:03:28 UTC) #1
nweiz
I'd like to see a test that running an executable in a transitive dependency fails ...
6 years, 6 months ago (2014-06-19 20:12:11 UTC) #2
Bob Nystrom
> I'd like to see a test that running an executable in a transitive dependency ...
6 years, 6 months ago (2014-06-20 00:14:20 UTC) #3
nweiz
lgtm https://codereview.chromium.org/341123002/diff/1/sdk/lib/_internal/pub/lib/src/command/run.dart File sdk/lib/_internal/pub/lib/src/command/run.dart (right): https://codereview.chromium.org/341123002/diff/1/sdk/lib/_internal/pub/lib/src/command/run.dart#newcode102 sdk/lib/_internal/pub/lib/src/command/run.dart:102: var mode = "--checked"; On 2014/06/20 00:14:20, Bob ...
6 years, 6 months ago (2014-06-20 02:08:28 UTC) #4
Sean Eagan
DBC https://chromiumcodereview.appspot.com/341123002/diff/20001/sdk/lib/_internal/pub/lib/src/command/run.dart File sdk/lib/_internal/pub/lib/src/command/run.dart (right): https://chromiumcodereview.appspot.com/341123002/diff/20001/sdk/lib/_internal/pub/lib/src/command/run.dart#newcode62 sdk/lib/_internal/pub/lib/src/command/run.dart:62: if (script.contains(":")) { Instead of inventing a syntax ...
6 years, 6 months ago (2014-06-20 12:42:39 UTC) #5
Bob Nystrom
Committed patchset #2 manually as r37561 (presubmit successful).
6 years, 6 months ago (2014-06-20 17:35:06 UTC) #6
Bob Nystrom
6 years, 6 months ago (2014-06-20 17:35:27 UTC) #7
Message was sent while issue was closed.
Thanks!

https://codereview.chromium.org/341123002/diff/20001/sdk/lib/_internal/pub/li...
File sdk/lib/_internal/pub/lib/src/barback/barback_server.dart (right):

https://codereview.chromium.org/341123002/diff/20001/sdk/lib/_internal/pub/li...
sdk/lib/_internal/pub/lib/src/barback/barback_server.dart:49: /// This server
serves assets from [barback], and use [rootDirectory]
On 2014/06/20 02:08:28, nweiz wrote:
> "use" -> "uses"

Done.

https://codereview.chromium.org/341123002/diff/20001/sdk/lib/_internal/pub/li...
sdk/lib/_internal/pub/lib/src/barback/barback_server.dart:59: log.fine('Bound
package serving to $host:$port.');
On 2014/06/20 02:08:28, nweiz wrote:
> I think "package: serving" might be a little clearer here.

Reworded to something better. What it binds is "package serving", so the colon
would be weird there.

https://codereview.chromium.org/341123002/diff/20001/sdk/lib/_internal/pub/li...
File sdk/lib/_internal/pub/lib/src/command/run.dart (right):

https://codereview.chromium.org/341123002/diff/20001/sdk/lib/_internal/pub/li...
sdk/lib/_internal/pub/lib/src/command/run.dart:62: if (script.contains(":")) {
On 2014/06/20 12:42:38, Sean Eagan wrote:
> Instead of inventing a syntax for this:
> 
>     pub run <package>:<path> [args...]
> 
> why not just use normal cli arguments:
> 
>     pub run [--package=<package>] <path> [args...]
> 
> ?

My hunch is that this will be a very common use case, so I wanted the syntax to
be lightweight. Something like:

$ pub run foo:bar arg arg

Having to do:

$ pub run --package foo bar arg arg

feels pretty painful to me.

Powered by Google App Engine
This is Rietveld 408576698