Skip to content

Instantly share code, notes, and snippets.


David Jack Wange Olrik davidolrik

View GitHub Profile

Keybase proof

I hereby claim:

  • I am davidolrik on github.
  • I am davidolrikdk ( on keybase.
  • I have a public key whose fingerprint is ECC3 95B7 9872 5570 D869 9DCB 5B3B AADE DDEE 156E

To claim this, I am signing this object:

davidolrik / init.lua
Created Apr 11, 2017 — forked from ttscoff/init.lua
Hammerspoon config examples for hyper key
View init.lua
-- A global variable for the Hyper Mode
k ={}, "F17")
-- Trigger existing hyper key shortcuts
k:bind({}, 'm', nil, function() hs.eventtap.keyStroke({"cmd","alt","shift","ctrl"}, 'm') end)
-- OR build your own
launch = function(appname)
davidolrik /
Last active Dec 23, 2015
Find the current active http proxy on OS X.
#!/usr/bin/env perl
use strict;
use warnings;
my $networksetup = `networksetup -listnetworkserviceorder`;
my @network_services = map { $_ =~ s/\(\d+\)\s+//; $_ } # 3. Remove (\d+) from begining of line
grep { /^\(\d+\)/ } # 2. Only look at lines starting with (\d+)
split(/\n/,$networksetup); # 1. Split into lines