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
; | |
; Provides functions for transforming data into JSON objects. | |
; | |
; This is Clojure code. | |
; | |
(defn data-to-json [list-this] | |
"Transforms a list into a string of JSON data" | |
(cond |
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
# Warbler web application assembly configuration file | |
Warbler::Config.new do |config| | |
# Temporary directory where the application is staged | |
# config.staging_dir = "tmp/war" | |
# Application directories to be included in the webapp. | |
config.dirs = %w(app config lib log vendor tmp extra lang) | |
# Additional files/directories to include, above those in config.dirs | |
# config.includes = FileList["db"] |
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
Next Meeting 3/12/2009, New Venue, New Format | |
We have a meeting coming up this week (Thursday the 12th). :) We’re also going to be meeting in a different place and we’ll be trying out an entirely new format! | |
Location | |
View Larger Map | |
We’ll be meeting up at the Snowtide office where Chas works. They have access to a good sized meeting room and Chas has been kind enough to volunteer it. It’s located in the Potpourri Plaza in Northampton, across the street from the Stop and Shop. | |
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
(progn | |
(let ((urls ())) | |
(save-excursion | |
(goto-char (point-min)) | |
(while | |
(re-search-forward | |
"\\<\\(http\\)://[a-zA-Z0-9\-\.\?\&\#]*" nil t) | |
(let ((start (match-beginning 0)) | |
(end (match-end 0))) | |
(setq urls (cons |
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
Fatal error: Uncaught exception 'com_exception' with message 'Failed | |
to create COM object `CAPICOM.Utilities.1': Invalid syntax ' in | |
D:\apache\intranet\www\ironlogin\installer\index.php:735 Stack trace: | |
#0 D:\apache\intranet\www\ironlogin\installer\index.php(735): | |
com->com('CAPICOM.Utiliti...') #1 | |
D:\apache\intranet\www\ironlogin\installer\index.php(161): | |
Install::GetRandomHash(8192) #2 | |
D:\apache\intranet\www\ironlogin\installer\index.php(55): | |
Install::CheckEnvironment() #3 | |
D:\apache\intranet\www\ironlogin\installer\index.php(24): |
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
(defn testing [reader-in] | |
(lazy-seq | |
(let [text []] | |
(let [int-in (next-character r)] | |
(if (not= int-in -1) | |
(conj text (char int-in)) | |
text))))) |
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
;; | |
;; Provides functions for managing links. | |
;; | |
(ns org.cooleydickinson.crawler.links | |
(:use [org.cooleydickinson.crawler.tagsoup :only (parse)]) | |
(:import (java.net URL))) | |
(defn canonicize | |
"Returns a canonical (not relative) URL for the supplied URL. The |
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
# | |
# A simple pre-forking server that tests to make sure the MySQL server | |
# is available. | |
# | |
# Based so heavily on the following article by Ryan Tomakyo that it's | |
# practically a verbatim copy. | |
# | |
# http://tomayko.com/writings/unicorn-is-unix | |
# | |
# Pasted at http://gist.github.com/213990 |
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 area | |
# only fetch the list of areas if we have a region | |
if !params[:region_id].blank? | |
@region = Region.find(params[:region_id]) | |
@areas = @region.areas | |
# save the selected region | |
session[:region_id] = @region.id |
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
(defn piece-line-breaks | |
"Returns a vector of the indexes of the line breaks in the piece of text" | |
[buffer piece] | |
(let [text-buffer (if (= (piece :buffer) :source) | |
@(buffer :source) | |
@(buffer :add))] | |
(reduce (fn [breaks index] | |
(if (= \newline (. text-buffer get index)) |
OlderNewer