This is a brief and bare-bones guide to getting GHC 7.2 and the cabal-install
tool (the two basic things you'll need to do Haskell development) up and running
on a new Mac OS X 10.7 install.
The instructions given here worked for me, but YMMV.
| ! Molokai theme | |
| *xterm*background: #101010 | |
| *xterm*foreground: #d0d0d0 | |
| *xterm*cursorColor: #d0d0d0 | |
| *xterm*color0: #101010 | |
| *xterm*color1: #960050 | |
| *xterm*color2: #66aa11 | |
| *xterm*color3: #c47f2c | |
| *xterm*color4: #30309b | |
| *xterm*color5: #7e40a5 |
| // pewpewpew | |
| // format: pauper | |
| // https://gist.github.com/952776 | |
| // Lands | |
| 10 Mountain | |
| 10 Island | |
| // Instants | |
| 4 Geistflame |
| // eek | |
| // format: 60 card | |
| // https://gist.github.com/965936 | |
| // Lands | |
| 20 Swamp | |
| // Creatures | |
| 40 Relentless Rats |
| // carpe noctem | |
| // format: 60 card | |
| // https://gist.github.com/967979 | |
| // Lands | |
| 8 Swamp | |
| 4 Peat Bog | |
| 4 Inkmoth Nexus | |
| // Instants |
| (*/!\ known bugs and shortcomings: | |
| - lacks integer overflow check, | |
| - lacks sign parsing (can't parse negative ints) | |
| - exceptions are not helpfull | |
| - code is ugly | |
| - should benchmark parse_int against parse_int_ | |
| *) | |
| let int_of_char c = match c with |
| #!/usr/bin/env runghc | |
| module Main where | |
| {- | |
| Uninstall.hs - a Haskell uninstaller for Mac OS X | |
| This program is really far too big to be in a single file. However, I | |
| wanted it to be easily distributable and runnable, and so have kept it all | |
| together. |
| #!/bin/bash | |
| # Script for placing sudoers.d files with syntax-checking | |
| # Making a temporary file to contain the sudoers-changes to be pre-checked | |
| TMP=$(mktemp -t vagrant_sudoers) | |
| cat /etc/sudoers > $TMP | |
| cat >> $TMP <<EOF | |
| # Allow passwordless startup of Vagrant when using NFS. | |
| Cmnd_Alias VAGRANT_EXPORTS_ADD = /usr/bin/su root -c echo '*' >> /etc/exports |
| (use '[clojure.core.match :only [match]]) | |
| (defn evaluate [env [sym x y]] | |
| (match [sym] | |
| ['Number] x | |
| ['Add] (+ (evaluate env x) (evaluate env y)) | |
| ['Multiply] (* (evaluate env x) (evaluate env y)) | |
| ['Variable] (env x))) | |
| (def environment {"a" 3, "b" 4, "c" 5}) |
| # ~/.osx — http://mths.be/osx | |
| ############################################################################### | |
| # General UI/UX # | |
| ############################################################################### | |
| # Set computer name (as done via System Preferences → Sharing) | |
| scutil --set ComputerName "MathBook Pro" | |
| scutil --set HostName "MathBook Pro" | |
| scutil --set LocalHostName "MathBook-Pro" |