Last Update: May 13, 2019
Offline Version
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
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>CFBundleDevelopmentRegion</key> <string>English</string> | |
<key>CFBundleExecutable</key> <string>upcase</string> | |
<key>CFBundleIdentifier</key> <string>com.caiochassot.services.upcase</string> | |
<key>CFBundleInfoDictionaryVersion</key> <string>6.0</string> | |
<key>CFBundlePackageType</key> <string>BNDL</string> |
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
framework "WebKit" | |
class Widget | |
class RPC | |
class << self | |
public :include | |
end | |
def initialize(widget) | |
@widget = widget |
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
This example expects to have d3.min.js and d3.layout.min.js in the same directory as pie.js and pie_serv.js. | |
Run with node pie_serv.js |
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
def performSearch(pred, &cb) | |
search = NSMetadataQuery.alloc.init | |
search.predicate = pred | |
search.searchScopes = [File.expand_path("~")] | |
NSNotificationCenter.defaultCenter.addObserverForName( | |
"NSMetadataQueryDidFinishGatheringNotification", object:nil, queue:nil, | |
usingBlock: Proc.new {|n| n.object.results.each {|r| cb.call(r) } }) | |
search.startQuery |
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 osx | |
(:use seesaw.core) | |
(:import | |
[com.apple.eawt Application ApplicationListener] | |
[java.awt.image BufferedImage])) | |
;; mostly for use with Seesaw | |
;; https://github.com/daveray/seesaw | |
(defn event-not-handled [e] (.setHandled e false)) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
;; Example implementation of Norvig's Spellchecker in Clojure, | |
;; using core.async | |
;; | |
;; There are probably some bugs in this. | |
;; | |
;; Original problem: https://github.com/ericnormand/spelling-jam | |
;; from Lambda Jam, Chicago, 2013: http://lambdajam.com/ | |
;; | |
;; Clojure core.async introduction: | |
;; http://clojure.com/blog/2013/06/28/clojure-core-async-channels.html |
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 todo-server.core | |
(:require | |
[cljs.nodejs :as nodejs] | |
[figwheel.client :as fw])) | |
(nodejs/enable-util-print!) | |
(defonce express (nodejs/require "express")) | |
(defonce serve-static (nodejs/require "serve-static")) | |
(defonce http (nodejs/require "http")) |
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 background | |
(:require [clojure.tools.logging :as log]) | |
(:import [java.util.concurrent])) | |
(defonce !executor (delay (java.util.concurrent.Executors/newCachedThreadPool))) | |
(defn background | |
"Calls the fn passed in a thread from a thread pool, returning immediately. | |
Unlike future, background does not swallow exceptions." | |
[f] |
OlderNewer