Google I/O Extended 2016 Baltimore

pic of screen

Today, I took the day off work and went into town to participate in Google I/O Extended Baltimore. Google I/O, of course, is a huge event out in California with about 7,000 people attending. Google I/O Extended is a series of related events all over the world. The event in Sri Lanka had over 2,000 people. Here in Baltimore, ours was held at AOL/ on Brewer’s Hill. Ossum!

pic of mr boh

We had a slate of live talks in the morning:

  • Chris Pino, “Entrepreneurial and Technical Challenges in the Personal Computer Age”
  • Will Gee, BaltiVirtual, “Beyond ‘The Year of VR'”
  • Scott Schopman, OrderUp, “Taking Mobile Testing to the Cloud with Google Cloud Test Lab”
  • Danny Blue, LiveSafe, “Intro to Angular 2”

Following a nice lunch, we watched the Keynote live from California on streaming video.

pic of Google I/O

Afterwards, there were VR demos from BaltiVirtual

pic of BaltiVirtual demo

It was a fun day! If you can’t make it to Google I/O next year, look for the Google I/O Extended event in your area!

Google I/O Extended 2016 Baltimore

Perl 5.24 on a stick

I just upgraded my Perl thumb drive to Strawberry Perl!

pic of Perl thumb drive

I simply reformatted it and unzipped the new one onto it

cd /media/tim/Strawberry
unzip ~/Downloads/

When I put the thumb drive in a Windows machine, it was mounted as the I: drive, so now I can use Strawberry Perl from cmd.exe

Microsoft Windows [Version 10.0.10586]
(c) 2015 Microsoft Corporation. All rights reserved.

C:\Users\tim>I:\perl\bin\perl -E "say qq{Hello, Perl $]}"
Hello, Perl 5.024000

or from PowerShell

PS C:\Users\tim> I:/perl/bin/perl -E "say qq{Hello, Perl $]}"
Hello, Perl 5.024000


Perl 5.24 on a stick

VS Code

One of the things I learned at Go Maryland tonight was that VS Code is not just for Windows; they have versions for Linux and OS X too! With a name like Visual Studio Code, I just assumed it was a Windows thing. Not so!

Naturally, when I got home I had to try it! And here it is running on my Linux machine!

Screen shot of VS Code

As you can see, it understands Go code (on the left), but not Elixir (on the right). At least, not yet. I’m sure it will eventually. I also tried out Perl (yes), Python (yes), and Ruby (yes) — no surprises there — as well as Erlang (no), Pony (no), Rust (yes), and Clojure (yes) — a couple of nice surprises there!

The cursor blinks by default, so the first thing I had to do was figure out how to shut that off 1. It only took me a minute or two to find and change the configuration to a non-blinking cursor. Well done, VS Code!

I doubt I’ll be giving up Emacs any time soon (indeed, I’m typing this blog entry with org2blog), but it’s nice to see another open source editor available. Great job, Microsoft!

Update: In case you’re curious, here’s a shot of the same two files opened in Emacs, which has an Elixir mode.

Screen shot of same two files in Emacs


I can’t stand blinking. I think it’s genetic. My Mom never let us have Christmas lights that blinked either. And to be fair, my beloved Emacs has a blinking cursor by default also
VS Code

Swift 2.2

A while back, I mentioned Swift was open sourced. Today, they released version 2.2, the first release with non-Apple contributors.

There are also binary releases, so it’s even easier to install!

$ wget{,.sig}
$ gpg --verify swift-2.2-RELEASE-ubuntu15.10.tar.gz.sig
$ tar xf swift-2.2-RELEASE-ubuntu15.10.tar.gz
$ rm swift-2.2-RELEASE-ubuntu15.10.tar.gz{,.sig}
$ export PATH=$PATH:$HOME/swift-2.2-RELEASE-ubuntu15.10/usr/bin
$ cd swift
$ rm hello
$ swiftc hello.swift
$ ./hello swift 2.2
Hello, swift!
Hello, 2.2!
Swift 2.2

Pony Lang

The other day, I watched Mark Allen‘s talk comparing Erlang and Go Concurrency and I really enjoyed it. Near the end, he mentioned a new programming language called Pony which uses the Actor Model.

What? I’ve never heard of this! So I did a search on “pony lang” and got a bunch of pictures of glamorous women. At first, I thought maybe there was an actress or model named Pony Lang. Then I realized they weren’t all pictures of the same person, though they did have similar hairstyles. It turns out “pony lang” is Dutch for “long bangs”.

Anyway, is where to start if you want to learn more about the Pony programming language. I installed it

sudo add-apt-repository "deb ponyc main"
sudo apt-get update
sudo apt-get install ponyc

added the Emacs mode for it

(use-package ponylang-mode
  :ensure t
     (lambda ()
       (set-variable 'indent-tabs-mode nil)
       (set-variable 'tab-width 2)))))

and dashed off hello world.

actor Main
  new create(env: Env) =>
  env.out.print("Hello, World!")

Now compile and run it!

$ cd ~/pony/helloworld
$ ponyc
Building . -> /home/tim/pony/helloworld
Building builtin -> /usr/lib/pony/0.1.7/packages/builtin
Writing ./helloworld.o
Linking ./helloworld
$ ./helloworld 
Hello, World!

Looks great! Another new language to learn! What fun!

Pony Lang

How to measure your CPU time: clock_gettime!

I loved reading How to measure your CPU time: clock_gettime! by Julia Evans.

In Perl, we can access clock_gettime throught the Time::HiRes module.

#!/usr/bin/env perl


use v5.22;
use warnings;
use Time::HiRes qw(clock_gettime CLOCK_PROCESS_CPUTIME_ID);

my $start_time = clock_gettime(CLOCK_PROCESS_CPUTIME_ID);
my $end_time = clock_gettime(CLOCK_PROCESS_CPUTIME_ID);
say "elapsed CPU time: ", $end_time - $start_time;

sub do_maybe_expensive_thing {
    my $j = 1;
    for my $i ( rand 100_000_000) {
        $j *= $i;

If we change do_maybe_expensive_thing to just a sleep, we’ll see that it takes up time without using CPU time.


How to measure your CPU time: clock_gettime!