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
| (def *enc-files-dir* "/home/blah/sandbox/enc") | |
| (def *dec-files-dir* "/home/blah/sandbox/dec") | |
| (defstruct file-map :filename :path :modified) | |
| (defn #^{:doc "Return vec of file-maps"} | |
| file-list [path] | |
| (vec | |
| (map (fn [n] | |
| (struct-map file-map |
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 application [text body] | |
| (html | |
| [:html | |
| [:head | |
| (include-js "/javascript/jquery.js" | |
| "/javascript/syntaxhilighter/scripts/shCore.js" | |
| "/javascript/syntaxhilighter/scripts/shBrushClojure.js" | |
| "/javascript/application.js") | |
| (include-css "/javascript/syntaxhilighter/styles/shCore.css" | |
| "/javascript/syntaxhilighter/styles/shThemeDefault.css" |
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
| 07:54 -!- Irssi: Join to #wikipedia was synced in 1 secs | |
| 07:54 < defn> Hello all -- I was wondering if there has been any talk about including pronounciation in wiki articles. | |
| 07:54 < defn> I often find something like: http://en.wikipedia.org/wiki/Podwale,_Świętokrzyskie_Voivodeship , how does one pronounce | |
| this? | |
| 07:55 < WikiziA62> Wikipedia EN can not be the scene of religious wars and persecution. This is against the pillars of the project. I | |
| am outraged at what is happening. I ask for help to Wikimedia | |
| 07:55 < defn> If I wish to know I must consult another website. | |
| 07:55 < defn> WikiziA62: Welcome to the real world. | |
| 07:55 < defn> WikiziA62: It's an ugly, but idealism only takes us so far. | |
| 07:55 < defn> ugly place* |
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 format-code | |
| [& codes] | |
| (apply str (map | |
| (fn [code] | |
| (if (string? code) | |
| (with-out-str | |
| (pprint | |
| (read | |
| (java.io.PushbackReader. | |
| (java.io.StringReader. code))))))) |
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
| file /Users/defn/bar.lua, init=flymake-lua-init | |
| flymake is running: nil | |
| file /Users/defn/bar.lua, init=flymake-lua-init [3 times] | |
| saved buffer bar.lua in file /var/folders/VI/VIRffdZAEqWd-12ad4QFtE+++TI/-Tmp-/flymake82252q0R | |
| started process 82456, command=(luac -p ../../var/folders/VI/VIRffdZAEqWd-12ad4QFtE+++TI/-Tmp-/flymake82252q0R), dir=/Users/defn/ | |
| received 122 byte(s) of output from process 82456 | |
| file /Users/defn/bar.lua, init=flymake-lua-init | |
| parse line: file-idx=1 line-idx=2 file=/opt/local/bin/luac: ../../var/folders/VI/VIRffdZAEqWd-12ad4QFtE+++TI/-Tmp-/flymake82252q0R line=1 text=unexpected symbol near `{' | |
| get-real-file-name: file-name=/opt/local/bin/luac: ../../var/folders/VI/VIRffdZAEqWd-12ad4QFtE+++TI/-Tmp-/flymake82252q0R real-name=/opt/local/bin/var/folders/VI/VIRffdZAEqWd-12ad4QFtE+++TI/-Tmp-/flymake82252q0R | |
| parsed '/opt/local/bin/luac: ../../var/folders/VI/VIRffdZAEqWd-12ad4QFtE+++TI/-Tmp-/flymake82252q0R:1: unexpected symbol near `{'', got line-err-info |
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
| ;; load paths | |
| (setq dotfiles-dir (file-name-directory | |
| (or (buffer-file-name) load-file-name))) | |
| (add-to-list 'load-path dotfiles-dir) | |
| (if (fboundp 'normal-top-level-add-subdirs-to-load-path) | |
| (let* ((my-lisp-dir "~/.emacs.d/elpa-to-submit") | |
| (default-directory my-lisp-dir)) | |
| (setq load-path (cons my-lisp-dir load-path)) |
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 check-user | |
| "Checks the nickname of the user. This functions as a basic authorization check for commands like \"!join\"." | |
| [nick f] | |
| (if (= nick "defn") | |
| f | |
| nil)) | |
| (def bot-fnmap | |
| {:on-message | |
| (fn [{:keys [nick channel message irc]}] |
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 check-user | |
| "Checks the nickname of the user. This functions as a basic authorization check for commands like \"!join\"." | |
| [nick f] | |
| (if (= nick "defn") | |
| f | |
| nil)) | |
| (def bot-fnmap | |
| {:on-message | |
| (fn [{:keys [nick channel message irc]}] |
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 rand-range [m n] | |
| (+ m (rand-int (- n m)))) | |
| (defn with-transient [x f] | |
| (persistent! (f (transient x)))) | |
| (defn swap-entries! [x i j] | |
| (assoc! x i (x j) j (x i))) | |
| (defn knuth-shuffle [xs] |
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
| (ns walton.layout | |
| (:use [hiccup core page-helpers form-helpers] | |
| walton.core)) | |
| (defn application [text body] | |
| (html | |
| [:html | |
| [:head | |
| (include-js "../../resources/public/javascript/syntaxhilighter/scripts/shCore.js" | |
| "../../resources/public/javascript/syntaxhilighter/scripts/shBrushClojure.js") |