Skip to content

Instantly share code, notes, and snippets.

View iquiw's full-sized avatar
🦛
Do not underestimate hippopotamus

Iku Iwasa iquiw

🦛
Do not underestimate hippopotamus
View GitHub Profile
@iquiw
iquiw / getdocker.sh
Last active September 10, 2016 13:28
Script to download docker.exe
#! /bin/sh
bundleURL=https://raw.githubusercontent.com/docker/toolbox/master/Dockerfile.windows
dockerBucket=get.docker.com
if [ -e docker ]; then
echo 'File or directory "docker" should not exist.'
exit 1
fi
@iquiw
iquiw / ghc-flycheck.el
Last active August 29, 2015 14:23
ghc-modi flycheck checkers
(require 'flycheck)
(setq-default flycheck-disabled-checkers '(haskell-ghc haskell-lint))
(defconst ghc-check-regexp
"^\\([^\n]*\\):\\([0-9]+\\):\\([0-9]+\\):\\(Warning:\\)? *\\([^\t]+\\)")
(defun ghc-flycheck-start (cmd checker callback)
(let ((errs (ghc-sync-process
(format "%s %s\n" cmd
@iquiw
iquiw / gist:10c49212fd59fc795c59
Created August 19, 2014 13:56
function-key-map
(keymap (27 . [escape]) (right-fringe keymap (mouse-3 . mouse--strip-first-event) (mouse-2 . mouse--strip-first-event) (mouse-1 . mouse--strip-first-event)) (left-fringe keymap (mouse-3 . mouse--strip-first-event) (mouse-2 . mouse--strip-first-event) (mouse-1 . mouse--strip-first-event)) (escape . [27]) (return . [13]) (clear . [12]) (linefeed . [10]) (tab . [9]) (kp-equal . [61]) (kp-separator . [44]) (kp-tab . [9]) (kp-space . [32]) (24 keymap (64 keymap (99 . event-apply-control-modifier) (83 . event-apply-shift-modifier) (97 . event-apply-alt-modifier) (109 . event-apply-meta-modifier) (115 . event-apply-super-modifier) (104 . event-apply-hyper-modifier))) (S-tab . [backtab]) (0 . [67108896]) (delete . [127]) (backspace . [127]) (C-M-S-kp-divide . [234881071]) (M-S-kp-divide . [167772207]) (C-S-kp-divide . [100663343]) (S-kp-divide . [33554479]) (C-M-kp-divide . [201326639]) (M-kp-divide . [134217775]) (C-kp-divide . [67108911]) (kp-divide . [47]) (C-M-S-kp-multiply . [234881066]) (M-S-kp-multiply . [1677
@iquiw
iquiw / gist:9156790
Created February 22, 2014 15:42
Turpial install instruction for Windows

Turpial install instruction for Windows

Prerequisite

  1. Python2.7 is installed (Python2.7.6)
  2. pip is installed. (pip)
@iquiw
iquiw / gist:5894128
Last active December 19, 2015 03:59
Modified TwoPane layout. Not changing second window on mouse focus change.
-- Derived from xmonad-contrib/XMonad/Layout/TwoPane.hs
data TwoPaneMod a = TwoPaneMod Rational Rational deriving (Show, Read)
instance LayoutClass TwoPaneMod Window where
doLayout (TwoPaneMod _ split) r s = (,Nothing) <$> arrange r s
where
arrange rect st = do
ws <- mapped <$> get
let x = case reverse (W.up st) of
(master:_) -> [(master, left), (W.focus st, right)]