This file contains hidden or 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 keyword-reader-macro.core | |
(:import [clojure.lang LispReader LispReader$StringReader])) | |
(defn field [] | |
(.getDeclaredField LispReader "dispatchMacros")) | |
(defn dispatch-macros [] | |
(.get (field) LispReader)) | |
(defn dispatch-reader! |
This file contains hidden or 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
global | |
lua-load '/servers/haproxy/superserver.lua' | |
frontend tailon-frontend | |
bind :9090 | |
tcp-request content set-var(txn.service_dir) str("/s6-supervised-servers/tailon") | |
tcp-request content lua.extend-life | |
default_backend tailon-backend | |
backend tailon-backend |
This file contains hidden or 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
self-installs |
This file contains hidden or 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
/target | |
/classes | |
/checkouts | |
pom.xml | |
pom.xml.asc | |
*.jar | |
*.class | |
/.lein-* | |
/.nrepl-port |
This file contains hidden or 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 test.core | |
(:require [ clojure.core.typed :as t ])) | |
(t/ann-protocol P2 | |
olol (t/IFn [P2 Kw * -> t/Any])) | |
(t/defprotocol> P2 | |
(olol [this & rest])) | |
(t/ann-record R2 []) | |
(defrecord R2 [] |
This file contains hidden or 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
*~ | |
.* | |
*.dat | |
*.eld | |
.smex-items | |
.emacs_workgroups_* | |
tmp* | |
places | |
ede-projects.* | |
ac-dict/ |
This file contains hidden or 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
package jp.ne.wakuwaku.test; | |
import jp.ne.wakuwaku.sdk.Wakuwaku; | |
import jp.ne.wakuwaku.sdk.Wakuwaku.Coupon; | |
import jp.ne.wakuwaku.sdk.Wakuwaku.InitException; | |
import jp.ne.wakuwaku.sdk.Wakuwaku.NoEmailProvidedException; | |
import jp.ne.wakuwaku.sdk.Wakuwaku.NoWalletInstalledException; | |
import android.app.Activity; | |
import android.app.AlertDialog; | |
import android.content.Context; |
This file contains hidden or 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
import scala.reflect.runtime.universe._ | |
class A[E](e:E)(implicit t: TypeTag[E]){ | |
def c(o:Any) = { | |
val TypeRef(_, klass_symbol, _) = t.tpe | |
println(s"ClassSymbol extracted from TypeTag[E] '${klass_symbol.asClass}' : ClassSymbol") | |
println(s"Class extracted from o:Any parameter = '${o.getClass}' : Class[??]") | |
runtimeMirror(getClass.getClassLoader).runtimeClass(klass_symbol.asClass) == o.getClass | |
} | |
} |
This file contains hidden or 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
#!/usr/bin/env ruby | |
# -*- coding: utf-8 -*- | |
`find "/Users/freakhill/Dropbox/アプリ/gutenberg" -name "*.epub"`.split("\n").each do |f| | |
File.basename(f) =~ /^(.*)\.epub$/ | |
title = $1 | |
if File.exists? File.join(File.dirname(f), "#{title}.mobi") | |
puts "skipping #{$1}" | |
next | |
end |
This file contains hidden or 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
#!/usr/bin/env ruby | |
# -*- coding: utf-8 -*- | |
# easy to break use at your own risk | |
# this script renames pdf files in a folder (and subfoler) (on unixy machines) | |
# with a naive heuristic to find the title (that unfortunately is never in the *title* metadata) | |
require 'pdf-reader' |
NewerOlder