Wednesday, February 27, 2013

Dart on a Chromebook: Success!

I finally have a viable approach to editing Dart directly on a Chromebook running ChromeOS! The usual approach to developing Dart code on a Chromebook is to use Chrome Remote Desktop to connect to another development machine. However, I wanted an approach that would let me develop in Dart while offline, for instance if I'm giving a talk on Dart and my internet connection goes down.

Crouton is a set of scripts based around debootstrap that bundle up into an easy-to-use, Chromium OS-centric Ubuntu chroot generator. Using Crouton, I was able to create a chroot running a basic Ubuntu setup. Within the chroot, I was able to install a JDK and then Dart Editor. Everything works, as you can see in the picture. I can switch back and forth between XFCE and ChromeOS's desktop using a key combination, and everything still runs at native speed since it's just a simple chroot.

I got everything working on my wife's Samsung Series 5 Chromebook running an Intel Atom processor. I have a newer ARM-based Chromebook, but there is currently no ARM port of the Dart VM. I used the 32-bit version of the JDK and the 32-bit version of Dart Editor.

I'm pretty excited that this works because this is one of the few things that was preventing me from fully switching to a Chromebook :) Now, all I need to do is get my hands on a Chromebook Pixel!

4 comments:

lch said...

Sweet! This makes the chromebook pixel viables as my next machine :)

Shannon Behrens said...

Exactly!

John said...

Nice! I got it working too using a similar technique :)

The main issue with it on the Pixel -- the high DPI of the retina display makes most of the Linux desktops look really bad (very tiny!). You can fix the fonts, but I haven't found anything yet to uniformly scale the UI.

Shannon Behrens said...

Good tip, thanks. Have you gotten copy-and-paste to work between the two desktops? I've gotten to a point where I have a proof-of-concept working, but I haven't gotten to the point where it's a really enjoyable setup.