Discover gists
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
foo := block(str, | |
str asMutable asCapitalized println | |
) | |
foo call("my awesome string") // ==> My awesome string | |
foo message // ==> str asMutable asCapitalized println | |
foo message next // ==> asMutable asCapitalized println | |
foo message next next // ==> asCapitalized println | |
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
<!-- | |
{ | |
"description": "& test 1", | |
"expect": {"bozo": false, ["entries", 0, "title_detail", "value"]: "&"]} | |
} | |
--> | |
<feed version="0.3" xmlns="http://purl.org/atom/ns#"> | |
<entry> | |
<title type="text/html" mode="escaped">&</title> | |
</entry> |
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
SELECT count(*) | |
FROM drug_order | |
INNER JOIN drug ON drug_order.drug_inventory_id = drug.drug_id | |
INNER JOIN concept_set as arv_drug_concepts ON | |
arv_drug_concepts.concept_set = 460 AND | |
arv_drug_concepts.concept_id = drug.concept_id | |
WHERE drug.concept_id IS NOT NULL; | |
=> | |
+----------+ | |
| count(*) | |
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
#!/bin/sh | |
# | |
# installgit.sh | |
# | |
# A bash script to install the latest version of Git. Be sure to set the variables to the desired values. | |
# | |
# http://git.or.cz/ | |
# | |
# Mark Eli Kalderon 2008-07-25 | |
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
// ==UserScript== | |
// @name Autopagerize for haiku | |
// @namespace http://rails2u.com/ | |
// @description works on Firefox, Opera, Safari and fub.net | |
// @include http://h.hatena.ne.jp/* | |
// @include http://h.hatena.com/* | |
// ==/UserScript== | |
(function(unsafeWindow){ | |
var getHeight = (function(){ |
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
select max(A) | |
from R | |
where R.B in (1,2,3,4,5,6,7,8,9,10) |
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
$:.unshift File.dirname(__FILE__) + '/../lib' | |
require 'mq' | |
EM.run do | |
# open a channel on the AMQP connection | |
channel = MQ.new | |
# declare a queue on the channel | |
queue = MQ::Queue.new(channel, 'queue name') |
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
#import "AppController.h" | |
#import "Person.h" | |
@implementation AppController | |
-(id)init | |
{ | |
NSLog(@"Initializing"); | |
people = [Person findAll]; | |
return self; | |
} |
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
_,,....,,_ _人人人人人人人人人人人人人人人_ | |
-''":::::::::::::`''> ゆっくりした結果がこれだよ!!! < | |
ヽ::::::::::::::::::::: ̄^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^Y^ ̄ | |
|::::::;ノ´ ̄\:::::::::::\_,. -‐ァ __ _____ ______ | |
|::::ノ ヽ、ヽr-r'"´ (.__ ,´ _,, '-´ ̄ ̄`-ゝ 、_ イ、 | |
_,.!イ_ _,.ヘーァ'二ハ二ヽ、へ,_7 'r ´ ヽ、ン、 | |
::::::rー''7コ-‐'"´ ; ', `ヽ/`7 ,'==─- -─==', i | |
r-'ァ'"´/ /! ハ ハ ! iヾ_ノ i イ iゝ、イ人レ/_ルヽイ i | | |
!イ´ ,' | /__,.!/ V 、!__ハ ,' ,ゝ レリイi (ヒ_] ヒ_ン ).| .|、i .|| | |
`! !/レi' (ヒ_] ヒ_ン レ'i ノ !Y!"" ,___, "" 「 !ノ i | |
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
%% @author Masahito Ikuta <cooldaemon@gmail.com> [http://d.hatena.ne.jp/cooldaemon/] | |
%% @copyright Masahito Ikuta 2008 | |
%% | |
%% @doc The sample module for the EDoc. | |
%% | |
%% I'm practicing writing the EDoc. | |
%% This file was made because of the practice. | |
%% | |
%% Here's a quick example illustrating how to use edoc_test: | |
%% ``` |