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
package blah | |
import ( | |
"sync/atomic" | |
) | |
var ( | |
n uint64 | |
) |
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
5.0 + | |
| | |
| | |
| +-----*-----+ | |
| | |
4.0 + | |
| | |
| | |
| +-----*-----+ |
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
14:17:33 ~ $ rustc --version | |
rustc 1.0.0-nightly (44a287e6e 2015-01-08 17:03:40 -0800) | |
14:17:36 ~ $ cargo --version | |
cargo 0.0.1-pre-nightly (8c01b6b 2015-01-08 20:52:43 +0000) | |
14:17:47 ~ $ cd /tmp | |
14:17:49 /tmp $ cargo new --bin hello-world | |
14:18:00 /tmp $ cd hello-world/ | |
/tmp/hello-world | |
14:18:04 /tmp/hello-world [git:master?] $ cargo run | |
An unknown error occurred |
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
### Keybase proof | |
I hereby claim: | |
* I am codahale on github. | |
* I am codahale (https://keybase.io/codahale) on keybase. | |
* I have a public key whose fingerprint is 5D14 B50E 62D6 279D 6C41 52DC DC59 AFA3 840C 3C96 | |
To claim this, I am signing this object: |
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 whack(objects) | |
return Hash[*objects.map{ |o| [o.send("table_name"), o.send("delete_all")] }.flatten] | |
end |
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
#!/usr/bin/env ruby | |
# Written by Coda Hale <coda.hale@gmail.com>. MIT License. Go for it. | |
def include_pattern(filename) | |
core = filename.gsub(/_spec/, "").gsub(/\Aspec\//, "") | |
return Regexp.quote(core) | |
end | |
if ARGV.empty? || ARGV == ["--help"] || ARGV == ["-h"] | |
STDERR.puts("Usage:") |
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
--- LastFM - Ban Current Track | |
set previousApp to name of (info for (path to frontmost application)) | |
tell application "Last.fm" to activate | |
tell application "System Events" to keystroke "b" using command down | |
open location "x-launchbar:hide" | |
tell application previousApp to activate |
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
# coda@lunchbox /L/R/G/1/specifications> less jsonpretty-1.0.0.gemspec | |
# -*- encoding: utf-8 -*- | |
Gem::Specification.new do |s| | |
s.name = %q{jsonpretty} | |
s.version = "1.0.0" | |
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version= | |
s.authors = ["Nick Sieger"] | |
s.date = %q{2009-02-19} |
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
#!/usr/bin/env ruby | |
$existing_methods = [] | |
def print_methods(library) | |
new_methods = [].methods.sort - $existing_methods | |
for method in new_methods | |
puts "Array##{method}" | |
end | |
puts "(total: #{new_methods.size} added by #{library})\n\n" |
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
@Path("/hello") | |
@Produces(MimeType.TEXT_PLAIN) | |
public class HelloResource { | |
@GET | |
public Response sayHello(@DefaultValue("stranger") @QueryParam("name") String name) { | |
return Response.ok("Hello, " + name).build(); | |
} | |
} |
OlderNewer