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
diff --git a/app/models/asset_terms.rb b/app/models/asset_terms.rb | |
index 7969cd8..78e2688 100644 | |
--- a/app/models/asset_terms.rb | |
+++ b/app/models/asset_terms.rb | |
@@ -4,22 +4,28 @@ class AssetTerms < ActiveRecord::Base | |
define_index do | |
indexes :identifier | |
indexes :title | |
- indexes :subject | |
+ # indexes :subject |
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
mlc@palm:~$ dig @a.nic.ch -t NS wikileaks.ch | |
; <<>> DiG 9.7.1-P2 <<>> @a.nic.ch -t NS wikileaks.ch | |
; (2 servers found) | |
;; global options: +cmd | |
;; Got answer: | |
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 16048 | |
;; flags: qr rd; QUERY: 1, ANSWER: 0, AUTHORITY: 13, ADDITIONAL: 4 | |
;; WARNING: recursion requested but not available |
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 | |
require 'rubygems' | |
require 'ffi-rzmq' | |
unless ARGV.size == 1 | |
$stderr.puts "please provide your client identifier on the command-line." | |
exit 1 | |
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
upstream thin { | |
server 127.0.0.1:9000; | |
server 127.0.0.1:9001; | |
server 127.0.0.1:9002; | |
} | |
server { | |
listen 80; | |
server_name pbcore.vermicel.li; |
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
mozilla's spidermonkey is written in C++ and has no problem: | |
mlc@palm:~$ smjs | |
js> "2.2250738585072012e-308" * 2 | |
4.450147717014403e-308 | |
js> | |
but try with rhino, which is written in Java: |
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
mlc@palm:~$ units | |
2411 units, 71 prefixes, 33 nonlinear units | |
You have: tempC(22) | |
You want: USD | |
conformability error | |
295.15 K | |
1 US$ |
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
mlc@palm:~$ units | |
2411 units, 71 prefixes, 33 nonlinear units | |
You have: 40 rod / hogshead | |
You want: mi / gal | |
* 0.001984127 | |
/ 504 |
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 | |
# | |
# This script downloads episodes of This American Life. It is useful | |
# because it downloads from the server normally use for streaming | |
# episodes in the flash player, so you can downoad episodes that are | |
# newer or older than the one currently available for podcast | |
# listening. | |
# |
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
# put into your Gemfile | |
gem 'chunky_png' | |
gem 'barby', :require => ['barby', 'barby/outputter/chunky_png_outputter'] |
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
public class Meetup { | |
public HttpResponse get(String url, List<? extends NameValuePair> params) throws IOException { | |
DefaultHttpClient cli = new DefaultHttpClient(); | |
cli.addRequestInterceptor(new HttpRequestInterceptor() { | |
@Override | |
public void process(HttpRequest httpRequest, HttpContext httpContext) throws HttpException, IOException { | |
httpRequest.addHeader(HttpHeaders.ACCEPT_CHARSET, "utf-8"); | |
} | |
}); |
OlderNewer