This file contains hidden or 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 perl | |
| use Modern::Perl; | |
| use Data::Dumper; | |
| use EV; | |
| use AnyEvent; | |
| use AnyEvent::HTTP; | |
| sub shot { | |
| my ($id) = @_; |
This file contains hidden or 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
| class Foo | |
| # has_many :bar | |
| attr_accessor :bar | |
| def method_missing(method, *args, &block) | |
| if method.to_s =~ /(\w+)_on/ | |
| raise Exception, "no condition given to filter `#{$1}'" unless args[0] | |
| result = self.send($1.to_sym) | |
| args[0].each { |field, value| | |
| result = result.select { |item| |
This file contains hidden or 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 file contains hidden or 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
| 質詢事項 | |
| 甲、行政院答復部分 | |
| (一)行政院函送李委員應元就政府進口含瘦肉精美牛等施政問題所提質詢之書面答復,請查照案。 | |
| (行政院函 中華民國101年10月9日院臺專字第1010061063號) | |
| (立法院函 編號:8-2-1-323) |
This file contains hidden or 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 perl | |
| # | |
| use Modern::Perl; | |
| package main; | |
| my @main::debug; | |
| push @main::debug, "log message"; |
This file contains hidden or 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
| abl-mode 0.9.0 installed Python TDD minor mode | |
| alpha 1.0 installed increase frame transparency | |
| applescript-mode 1.1 installed major mode for editing AppleScript source | |
| birds-of-paradi... 20120811.... installed A brown/orange light-on-dark theme for Emacs 24 (deftheme). [source: github] | |
| coffee-mode 20121004.... installed Major mode to edit CoffeeScript files in Emacs [source: github] | |
| color-theme 20080305.834 installed install color themes [source: bzr] | |
| color-theme-rai... 0.0.2 installed Railscasts color theme for GNU Emacs. | |
| color-theme-san... 20121001.936 installed A version of Ethan Schoonover's Solarized themes [source: github] | |
| cperl-mode 20110624.... installed Perl code editing commands for Emacs [source: github] | |
| erlang 20120831.... installed No description available. [source: github] |
This file contains hidden or 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/bash | |
| # Install script for the Darwin Streaming Server | |
| # source release | |
| echo;echo Installing Darwin Streaming Server;echo | |
| INSTALL_OS=`uname` |
This file contains hidden or 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
| $ua->request( | |
| HTTP::Request->new(GET => $URL), | |
| sub { | |
| my($chunk, $res) = @_; | |
| # do something on $chunk | |
| } | |
| ); |
This file contains hidden or 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 perl | |
| use Modern::Perl; | |
| use Plack; | |
| use MogileFS::Client; | |
| my $client = MogileFS::Client->new( domain => "test", hosts => ["localhost:7001"] ); | |
| use HTTP::Request; |