This file contains 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
the AJAX call succeeded! |
This file contains 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
the AJAX CALL SUCCEEEDEDEDEDDDDD |
This file contains 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
#!/bin/bash | |
yum groupinstall 'Development tools' -y | |
yum install ncurses ncurses-devel wget git -y | |
cd /usr/local/src | |
wget ftp://ftp.vim.org/pub/vim/unix/vim-7.4.tar.bz2 | |
tar -xjf vim-7.4.tar.bz2 | |
cd vim74 | |
./configure --prefix=/usr --with-features=huge --enable-rubyinterp --enable-pythoninterp | |
make && make install |
This file contains 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
### Keybase proof | |
I hereby claim: | |
* I am holguinj on github. | |
* I am justinh (https://keybase.io/justinh) on keybase. | |
* I have a public key whose fingerprint is 599E BD9F F53F 6F4B 1579 8122 0B52 DC36 64FE C3D1 | |
To claim this, I am signing this object: |
This file contains 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
#!/bin/bash | |
sudo apt-get install git -y | |
cd /usr/local/src | |
wget ftp://ftp.vim.org/pub/vim/unix/vim-7.4.tar.bz2 | |
tar -xjf vim-7.4.tar.bz2 | |
cd vim74 | |
./configure --prefix=/usr --with-features=huge --enable-rubyinterp --enable-pythoninterp | |
make && sudo make install |
This file contains 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
(defun new-lein-project (name &optional template) | |
"Interactively ask for a project and optional template name, | |
then create a Leiningen project with the parameters | |
and open its project.clj file." | |
(interactive "sProject name: \nMTemplate (optional): ") | |
(shell-command-to-string | |
(concat "cd ~/src && " ;; change this to the directory where you keep your projects | |
"lein new " | |
template | |
" " name)) |
This file contains 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 unconditional-fizz-buzz | |
"Note: this namespace occupies a bizarro world where there are no conditionals." | |
(:refer-clojure :exclude [case cond cond-> cond->> condp if if-let | |
if-not if-some when when-let when-not when-some])) | |
(defn not-divisible-by | |
"Given a number (divisor), returns a closure that: takes a numerator and returns | |
false (divisible) or the numerator. Please excuse the double negative; it's just | |
that false is easier to replace later on." | |
[n] |
This file contains 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 clj-tcx.core | |
(:require [clojure.data.xml :as xml] | |
[clojure.java.io :as io] | |
[clojure.walk :refer [postwalk]])) | |
(defmulti tcx-walker | |
"A multimethod that converts xml.Elments into Clojure maps and | |
LazySeqs into either bare strings or vectors depending on context. | |
Calls identity otherwise. Should be used to walk a parsed XML tree | |
to make it look more like an idiomatic Clojure data structure." |
This file contains 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
#!/bin/bash | |
#### lt -- a wrapper around "lein test" | |
# The purpose of this script is to provide some conveniences around | |
# running Leiningen tests. Specifically, it does the following: | |
# 1) fails if there any unsaved Emacs buffers | |
# 2) prints out any lines containing "DEBUG" or Spyscope statements | |
# 3) runs the test with the supplied arguments | |
# | |
# unofficial strict mode |
This file contains 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
;; Run with M-x create-migration | |
(defun current-datestamp () | |
;; 2014 01 14 13 17 03 | |
;; %Y %m %d %H %M %S | |
(let ((datestamp-format "%Y%m%d%H%M%S")) | |
(format-time-string datestamp-format (current-time)))) | |
(defun create-migration (name directory) | |
(interactive "sMigration name: \nDWhere?") |
OlderNewer