Skip to content

Instantly share code, notes, and snippets.

View mattiasb's full-sized avatar

Mattias Bengtsson mattiasb

View GitHub Profile
@mattiasb
mattiasb / gist:c84ab498d444df108bf7
Created October 13, 2014 18:52
Mmm JavaScript.
// test.js
let v1 = "wee";
let v2 = "gaah";
function test() {
return
[v1,v2].join(' ');
}
<object class="GtkGrid" id="no-network-conn-message">
<property name="visible">True</property>
<property name="orientation">vertical</property>
<property name="margin-start">15</property>
<child>
<object class="GtkLabel" id="message1">
<attributes>
<attribute name="weight" value="bold" />
<attribute name="scale" value="2.0" />
</attributes>
@mattiasb
mattiasb / Makefile
Created May 26, 2014 04:07
Makefile for initializing tz_world.sqlite
all: tz_world.sqlite
tz_world.sqlite: tz_world.zip /usr/bin/spatialite_tool
unzip tz_world.zip
spatialite_tool -i -shp world/tz_world -t tz_world -d tz_world.sqlite -c CP1252
rm -r world
tz_world.zip: /usr/bin/curl
curl "http://efele.net/maps/tz/world/tz_world.zip" -o tz_world.zip
const Transportation = {
CAR: 0,
BIKE: 1,
PEDESTRIAN: 2
};
Transportation.toString = function toString(transportation) {
};
@mattiasb
mattiasb / 99-touchpad-fixes.sh
Created March 22, 2014 15:37
Touchpad fix on Ideapad Yoga 2 pro
#!/bin/bash
# I put this in /etc/X11/xinit/xinitrc.d/99-touchpad-fixes.sh
xinput set-prop "SynPS/2 Synaptics TouchPad" "Device Accel Profile" 2
xinput set-prop "SynPS/2 Synaptics TouchPad" "Device Accel Constant Deceleration" 4
xinput set-prop "SynPS/2 Synaptics TouchPad" "Device Accel Adaptive Deceleration" 4
xinput set-prop "SynPS/2 Synaptics TouchPad" "Device Accel Velocity Scaling" 8
xinput set-prop "SynPS/2 Synaptics TouchPad" "Synaptics Finger" 35 45 0
xinput set-prop "SynPS/2 Synaptics TouchPad" "Synaptics Coasting Speed" 5 15