Skip to content

Instantly share code, notes, and snippets.

View liquidz's full-sized avatar
👶
hello world!

Iizuka Masashi liquidz

👶
hello world!
View GitHub Profile
@thash
thash / project.clj
Last active December 17, 2015 00:19
Skype.appがローカルにSQLiteで保存しているチャット履歴を引っ張り出してEverNoteに突っ込むスクリプト. 1日の履歴をチャット窓ごとに分割されたNoteとして保存する usage: lein run 20130505
(defproject skype2ever "HEAD"
:repositories {"sonatype" "https://oss.sonatype.org/content/groups/public/"}
:local-repo "lib"
:dependencies [[org.clojure/clojure "1.5.1"]
[org.clojure/java.jdbc "0.3.0-alpha1"]
[org.xerial/sqlite-jdbc "3.7.2"]
[com.evernote/evernote-api "1.23"]
]
:main skype2ever.main)
(ns foo.core
(:require
[clostache.parser :as clostache]
[cuma.core :as cuma]))
(def MAX_NUM 10000)
(defmacro time*
[expr]
`(let [start# (. System (nanoTime))
@juno
juno / github-flow.ja.md
Last active April 9, 2021 02:20
GitHub Flow (Japanese translation) Latest version is here: https://gist.github.com/Gab-km/3705015

GitHub Flow

31 Aug 2011

git-flowの問題点 (Issues with git-flow)

私は人々にGitを教えるためにあちこちを飛び回っているが、最近のほぼすべてのクラスやワークショップでgit-flowについてどう思うかを尋ねられた。私はいつも、git-flowは素晴らしいと思うと答えている。何百万ものワークフローを持ったシステム(Git)を提供し、ドキュメントもあるし、よくテストされている。フレキシブルなワークフローは、実に容易なやり方で多くの開発者の役に立つ。標準的なものになりつつあり、開発者はプロジェクトや企業の間を移動しつつこの標準的なワークフローに馴染むことができる。

@weavejester
weavejester / gist:1001206
Created May 31, 2011 20:27
Clojure on Heroku
~/$ lein new ring-on-heroku
Created new project in: /home/jim/Development/ring-on-heroku
~/$ cd ring-on-heroku
~/ring-on-heroku$ echo 'web: lein run -m ring-on-heroku.core' > Procfile
~/ring-on-heroku$ cat > src/ring_on_heroku/core.clj
(ns ring-on-heroku.core
(:use ring.util.response
ring.adapter.jetty))
(defn app [req]
@slagyr
slagyr / gist:950574
Created May 1, 2011 15:22
Game of Life in 8 lines of Clojure
(defn neighbors-of [cell]
(set (for [dx [-1 0 1] dy [-1 0 1] :when (not (= [dx dy] [0 0]))]
[(+ dx (first cell)) (+ dy (second cell))])))
(defn alive? [[cell freqs] world]
(or (and (= 2 freqs) (contains? world cell)) (= 3 freqs)))
(defn tick [world]
(let [frequencies (frequencies (reduce #(concat %1 (neighbors-of %2)) [] world))]
(set (keys (filter #(alive? % world) frequencies)))))