Goals: Add links that are reasonable and good explanations of how stuff works. No hype and no vendor content if possible. Practical first-hand accounts of models in prod eagerly sought.
Peter Naur's classic 1985 essay "Programming as Theory Building" argues that a program is not its source code. A program is a shared mental construct (he uses the word theory) that lives in the minds of the people who work on it. If you lose the people, you lose the program. The code is merely a written representation of the program, and it's lossy, so you can't reconstruct
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
;; Unlike fully lazy languages such as Haskell, Clojure seqs often implement chunking. | |
;; This means that when accessing the first element of a sequence, 32 members will be evaluated. | |
;; An example of this can be seen by implementing some side effect in a map. | |
(first (map (fn [x] (prn x) x) (range 5))) ;; prints 0 through 4, then returns 0 | |
;; The above example will return 0 (as expected), but you'll notice it prints off all 5 elements | |
;; of (range 5). | |
;; In the next case we can see that the evaluation caused by the access of the first element stops after | |
;; the first 32 elements are evaluated. |
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
;; SEE: https://github.com/cgrand/macrovich | |
;; macros and code in a single cljc working across clj, cljs and self-hosted cljs | |
;; require clojurescript from master | |
(ns foo.core | |
#?(:cljs (:require-macros | |
[net.cgrand.meta-macros :refer [macros no-macros]] | |
[foo.core :refer [add]]) | |
:clj (:require |
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
digraph G { | |
ranksep=1.0; | |
ratio=0.6; | |
APL [color=Blue, shape=box]; | |
Simula [color=Blue, shape=box]; | |
LISP [color=Blue, shape=box]; | |
ALGOL [color=Blue, shape=box]; | |
Planner [color=Blue, shape=box]; | |
ACTOR [shape=hexagon]; |
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
#do all as root: | |
#(download and install jdk-6u26-linux-amd64.rpm from Oracle) | |
alternatives --install /usr/bin/java java /usr/java/latest/bin/java 1500 | |
alternatives --set java /usr/java/latest/bin/java | |
alternatives --install /usr/lib/jvm/jre-1.6.0 jre_1.6.0 /usr/java/latest 1500 | |
alternatives --set jre_1.6.0 /usr/java/latest |
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/sh | |
# TODO: fold into ant (current) or maven (future). | |
# example usage (run from top-level zookeeper directory) : | |
# | |
# src/repeat.sh ZooKeeperTest | |
test_output=yes | |
testcase=$1 | |
i=0 | |
ant test-init |
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/sh | |
# example usage (run in top-level HBase directory) : | |
# | |
# src/repeat.sh TestRegionServerCoprocessorExceptionWithAbort | |
testcase=$1 | |
# see also http://hbase.apache.org/book/hbase.tests.html | |
i=0 | |
mvn clean | |
while [ "$?" -eq "0" ] ; do |
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 CHEATSHEET | |
;; | |
;; * :require makes functions available with a namespace prefix | |
;; and optionally can refer functions to the current ns. | |
;; | |
;; * :import refers Java classes to the current namespace. | |
;; | |
;; * :refer-clojure affects availability of built-in (clojure.core) | |
;; functions. |