We will use both of these in this class:
Download from: http://www.mapbox.com/mapbox-studio/ Download this! (150 MB)
Download from: http://www.mapbox.com/tilemill/ Download this! (58.9 MB)
id=$(docker ps | grep myimage:latest | awk '{ print $1 }') | |
docker pull quay.io/nnarhinen/myimage | |
new_id=$(docker run -d -p 3000 \ | |
-e ENVIRONMENT=PRODUCTION quay.io/nnarhinen/myimage) | |
id=$new_id ./update-nginx-port.bash | |
docker stop $id |
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>IndexDB Demo - Version 1.1</title> | |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> | |
<meta name="author" content="Ido Green"/> | |
</head> | |
<style> | |
#footer { | |
background-color: yellowgreen; |
(def history (Html5History.)) | |
(.setUseFragment history false) | |
(.setPathPrefix history "") | |
(.setEnabled history true) | |
(let [navigation (listen history EventType/NAVIGATE)] | |
(go | |
(while true | |
(let [token (.-token (<! navigation))] | |
(secretary/dispatch! token))))) |
We will use both of these in this class:
Download from: http://www.mapbox.com/mapbox-studio/ Download this! (150 MB)
Download from: http://www.mapbox.com/tilemill/ Download this! (58.9 MB)
packages: | |
yum: | |
git: [] | |
gcc: [] | |
make: [] | |
openssl-devel: [] | |
commands: | |
00-add-home-variable: | |
command: sed -i 's/function error_exit/export HOME=\/root\n\nfunction error_exit/' /opt/elasticbeanstalk/hooks/appdeploy/pre/50npm.sh | |
container_commands: |
FROM debian:wheezy | |
ENV DEBIAN_FRONTEND noninteractive | |
# Oracle Java 8 | |
RUN apt-get update \ | |
&& apt-get install -y wget openssl ca-certificates \ | |
&& cd /tmp \ | |
&& wget -qO jdk8.tar.gz \ |
autoload -Uz vcs_info | |
zstyle ':vcs_info:*' stagedstr '%F{green}●' | |
zstyle ':vcs_info:*' unstagedstr '%F{yellow}●' | |
zstyle ':vcs_info:*' check-for-changes true | |
zstyle ':vcs_info:(sv[nk]|bzr):*' branchformat '%b%F{1}:%F{11}%r' | |
zstyle ':vcs_info:*' enable git svn | |
theme_precmd () { | |
if [[ -z $(git ls-files --other --exclude-standard 2> /dev/null) ]] { | |
zstyle ':vcs_info:*' formats '%c%u%B%F{green} ' |
(defn emap-to-hash-map [e] | |
(cond | |
(or | |
(-> e class .toString (clojure.string/split #" ") second (= "datomic.query.EntityMap")) | |
(map? e)) (reduce-kv (fn [m k v] (assoc m k (emap-to-hash-map v))) {} (into {} e)) | |
(coll? e) (map emap-to-hash-map e) | |
:else e)) |
(use '[datomic.api :only [q db] :as d]) | |
(def uri "datomic:mem://accounts") | |
;; create database | |
(d/create-database uri) | |
;; connect to database | |
(def conn (d/connect uri)) |
$ -> | |
version = Number(document.location.hash.replace('#', '')) | |
data = [[3,7,9,1,4,6,8,2,5], [5,2,3,4,9,6,4,6,8]] | |
[pt, pl, pr, pb] = [20, 20, 20, 20] # padding | |
w = 800 - (pl + pr) | |
h = 300 - (pt + pb) | |
max = d3.max(data, (d) -> d3.max(d)) | |
# Scales | |
x = d3.scale.linear().domain([0, data[0].length - 1]).range [0, w] |