Rewrite of Travvik for Pebble