autocmd BufWritePre * :%s/\s\+$//e
(add-hook 'before-save-hook 'delete-trailing-whitespace)
| Jeremy | |
| Absolutely brilliant | |
| both technically | |
| and oratorically | |
| He wrote CoffeeScript | |
| 1st place 5k | |
| 21 min, 3 seconds | |
| <7min mile | |
| Big picture |
| require 'gollum/frontend/app' | |
| require 'digest/sha1' | |
| class App < Precious::App | |
| User = Struct.new(:name, :email, :password_hash) | |
| before { authenticate! } | |
| helpers do | |
| def authenticate! |
| -module(flashpolicy). | |
| -vsn("0.9.01"). | |
| -export([ start/0, stop/0 ]). | |
| -export([ init/3 ]). | |
| -export([ wait/2 ]). | |
| -define(POLICY_FILE, "/path/to/policyfile.xml"). | |
| start() -> | |
| start(?POLICY_FILE, 843, 3 ). |
| <?xml version="1.0"?> | |
| <!DOCTYPE cross-domain-policy SYSTEM "/xml/dtds/cross-domain-policy.dtd"> | |
| <!-- Policy file for xmlsocket://socks.example.com --> | |
| <cross-domain-policy> | |
| <!-- This is a master socket policy file --> | |
| <!-- No other socket policies on the host will be permitted --> | |
| <site-control permitted-cross-domain-policies="master-only"/> |
| == DELEGATING WITH method_missing == | |
| = This works: | |
| send(method, *args, &block) | |
| ...but it can use lots of memory: see http://blog.pluron.com/2008/02/rails-faster-as.html | |
| = This works: |
| For each Ruby module/class, we have Ruby methods on the left and the equivalent | |
| Clojure functions and/or relevant notes are on the right. | |
| For clojure functions, symbols indicate existing method definitions, in the | |
| clojure namespace if none is explicitly given. clojure.contrib.*/* functions can | |
| be obtained from http://github.com/kevinoneill/clojure-contrib/tree/master, | |
| ruby-to-clojure.*/* functions can be obtained from the source files in this | |
| gist. | |
| If no method symbol is given, we use the following notation: |