gravatar
raynes has 414 public pastes.
Paste 66072
March 26, 2014
1
2
3
4
5
(defn red-green-blue-cycle [& {:keys [transition switches sleep]
                               :or {transition nil, sleep 100}}]
  (let [colors (cycle [0 25718 46920])
        lights (cycle [1 2 3 2 1])
        swaps (partition 2 (interleave lights colors))]
more...

Paste 63083
March 22, 2014
1
2
3
4
5
(defn red-green-blue-cycle [& {:keys [transition switches sleep]
                               :or {transition nil, sleep 100}}]
  (let [colors (cycle [0 25718 46920])
        lights (cycle [1 2 3 2 1])
        swaps (partition 2 (interleave lights colors))]
more...

Paste 59737
March 17, 2014
1
2
3
4
5
(defn red-green-blue-cycle [& [n]]
  (let [colors (cycle [0 25718 46920])
        lights (cycle [1 2 3 2 1])
        switches (partition 2 (interleave lights colors))]
    (doseq [[light hue] (if n
more...

Paste 57623
March 13, 2014
1
2
3
4
5
(defn camel->keyword
  [camel]
  (as-> camel x
        (str/split x  #"(?<=[a-z])(?=[A-Z])")
        (interpose \- x)
more...

Paste 49060
February 28, 2014
1
2
3
4
5
:orwell.freenode.net NOTICE * :*** Looking up your hostname...
:orwell.freenode.net NOTICE * :*** Checking Ident
:orwell.freenode.net NOTICE * :*** Found your hostname
:orwell.freenode.net NOTICE * :*** No Ident response
:orwell.freenode.net 431 * :No nickname given
more...

Paste 33278
February 5, 2014
1
foo

Paste 33277
February 5, 2014
1
2
3
4
5
def should_log(last, day):
    """If day and last aren't the same day AND
    last isn't today, log a refresh.

    """
more...

Paste 28237
January 27, 2014
1
2
3
4
5
$ node pult-server.js
spawning with sudo...

events.js:72
        throw er; // Unhandled 'error' event
more...

Paste 27451
January 25, 2014
1
2
3
"foo bar
baz
lol"

Paste 27051
January 24, 2014
1
2
3
4
5
(defun set-the-fucking-virtualenv-directory (root)
  (interactive (list (read-directory-name "Project root:")))
  (setq virtualenv-root root))

(global-set-key (kbd "C-c C-s") 'set-the-fucking-virtualenv-directory)

Did you know? CLOSE

  • There are keyboard shortcuts!
    • When Creating A Paste
      • ALT+P Toggle Private
      • CTRL+Enter Create Paste
      • ALT+W Toggle word wrap
    • When Viewing A Paste
      • ALT+G Go to a line
      • ALT+CTRL+E Edit the paste
      • ALT+R Show the raw code
  • There are URL options!
    • When Creating A Paste
      • ?lang=Javascript to default to javascript
    • When Viewing A Paste
      • #L-N Jump to line number N
?