How to change PUB.DART.SNAPSHOT from https://pub.dartlang.org to http://pub.dartlang.org ?

120 views
Skip to first unread message

Bernd Wessels

unread,
Dec 3, 2013, 8:05:30 PM12/3/13
to mi...@dartlang.org
Hi
as you may know there are issues with PUB behind a proxy.

To fix it I have to change the pub address in pub.dart.snapshot from "https://pub.dartlang.org" to "http://pub.dartlang.org".

But where is the PUB code and how do I create a new snapshot?

Cheers
Bernd

Bob Nystrom

unread,
Dec 3, 2013, 8:07:49 PM12/3/13
to General Dart Discussion

On Tue, Dec 3, 2013 at 5:05 PM, Bernd Wessels <wessel...@gmail.com> wrote:
But where is the PUB code and how do I create a new snapshot?

Pub lives in the Dart repo under <repo>/sdk/lib/_internal/pub. If you sync the repo and build the SDK, that will include generating a new pub snapshot. (If you have the repo synced and built, you can also run pub directly from source by invoking <repo>sdk/bin/pub.

Details on getting and building the SDK are here: https://code.google.com/p/dart/wiki/Contributing

Cheers!

- bob

Bernd Wessels

unread,
Dec 3, 2013, 8:33:19 PM12/3/13
to mi...@dartlang.org
Thanks Bob.

Is there a good explanation on how to create the pub.dart.snapshot (or how to build a snapshot at all)?

Cheers
Bernd


--
For other discussions, see https://groups.google.com/a/dartlang.org/
 
For HOWTO questions, visit http://stackoverflow.com/tags/dart
 
To file a bug report or feature request, go to http://www.dartbug.com/new

Bob Nystrom

unread,
Dec 4, 2013, 1:23:11 PM12/4/13
to General Dart Discussion

On Tue, Dec 3, 2013 at 5:33 PM, Bernd Wessels <wessel...@gmail.com> wrote:
Is there a good explanation on how to create the pub.dart.snapshot (or how to build a snapshot at all)?

From hunting through the build files, for pub it looks like it's just:

dart --package-root=<...> --snapshot=/pub.dart.snapshot ../../sdk/lib/_internal/pub/bin/pub.dart

So I think you just invoke a Dart entrypoint with "--snapshot=<output file>" and it will compile a snapshot instead of running it. I don't know if there's real docs for this somewhere.

Cheers!

- bob

Bernd Wessels

unread,
Dec 4, 2013, 2:13:50 PM12/4/13
to mi...@dartlang.org
Thanks, I will try that.

You can't believe how incredible difficult and frustrating it is to get Dart up and running behind a corporate firewall/proxy. I wonder if anybody was ever able to get pub running through a ISA NTLM proxy, which is really really common in most Microsoft based enterprise companies?!

Cheers
Bernd


Bob Nystrom

unread,
Dec 4, 2013, 6:28:41 PM12/4/13
to General Dart Discussion
On Wed, Dec 4, 2013 at 11:13 AM, Bernd Wessels <wessel...@gmail.com> wrote:
You can't believe how incredible difficult and frustrating it is to get Dart up and running behind a corporate firewall/proxy.

We have gotten a lot of feedback about this, so I can certainly believe it. The challenge is that our corporate environment isn't set up like that, so it's hard for us to reproduce and fix issues related to it.

I'd really like pub to work better here, but I have pretty limited visibility into the issues. If you have any suggestions or, even better, patches that will help pub here, I'd love to see them.

Cheers,

- bob

Reply all
Reply to author
Forward
0 new messages