This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 13:15 <xQuasar> | HASKELL IS FOR FUCKIN FAGGOTS. YOU'RE ALL A BUNCH OF | |
| | FUCKIN PUSSIES | |
| 13:15 <xQuasar> | JAVASCRIPT FOR LIFE FAGS | |
| 13:16 <luite> | hello | |
| 13:16 <ChongLi> | somebody has a mental illness! | |
| 13:16 <merijn> | Wow...I suddenly see the error of my ways and feel | |
| | compelled to write Node.js! | |
| 13:16 <genisage> | hi | |
| 13:16 <luite> | you might be pleased to learn that you can compile | |
| | haskell to javascript now |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (defn- convert-db-uri [db-uri] | |
| (let [[_ user password host port db] (re-matches #"postgres://(?:(.+):(.*)@)?([^:]+)(?::(\d+))?/(.+)" db-uri)] | |
| {:user user | |
| :password password | |
| :host host | |
| :port (or port 80) | |
| :db db})) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ;SMBDIS.ASM - A COMPREHENSIVE SUPER MARIO BROS. DISASSEMBLY | |
| ;by doppelganger (doppelheathen@gmail.com) | |
| ;This file is provided for your own use as-is. It will require the character rom data | |
| ;and an iNES file header to get it to work. | |
| ;There are so many people I have to thank for this, that taking all the credit for | |
| ;myself would be an unforgivable act of arrogance. Without their help this would | |
| ;probably not be possible. So I thank all the peeps in the nesdev scene whose insight into | |
| ;the 6502 and the NES helped me learn how it works (you guys know who you are, there's no |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import Control.Exception | |
| import Control.Monad | |
| import Control.Monad.IO.Class | |
| import Data.ByteString.Lazy (ByteString) | |
| import Data.ByteString.Lazy.UTF8 (toString) | |
| import Data.Function | |
| import Data.Enumerator | |
| import Data.List | |
| import Data.Maybe |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (defn ellip-2 [words] | |
| (str (->> words (re-split #"\s+") (take 3) (str-join " ")) "...")) | |
| ; What does this do? Well, it ellipsizes sentences. it's an improvement upon the book's version. | |
| ; we send it strings like "Yo this is a test sentence!" and we get back "Yo this is..." | |
| ; legitimately useful for creating things like short descriptions to articles. | |
| ; you call it like | |
| (ellip-2 "Yo this is a test sentence!") |
NewerOlder