Skip to content

Instantly share code, notes, and snippets.

View typester's full-sized avatar
😇

Daisuke Murase typester

😇
View GitHub Profile
(defun xcode-buildandrun ()
(interactive)
(do-applescript "tell application \"Xcode\"
activate
end tell
tell application \"System Events\"
key code 15 using {command down}
end tell"))
From 837ffd5cd282df217863cb5593271d66308d4bd7 Mon Sep 17 00:00:00 2001
From: Daisuke Murase <typester@cpan.org>
Date: Thu, 17 Sep 2009 19:21:44 +0900
Subject: [PATCH] add on_error to stream handler
---
lib/AnyEvent/Twitter/Stream.pm | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/lib/AnyEvent/Twitter/Stream.pm b/lib/AnyEvent/Twitter/Stream.pm
From 837ffd5cd282df217863cb5593271d66308d4bd7 Mon Sep 17 00:00:00 2001
From: Daisuke Murase <typester@cpan.org>
Date: Thu, 17 Sep 2009 19:21:44 +0900
Subject: [PATCH] add on_error to stream handler
---
lib/AnyEvent/Twitter/Stream.pm | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/lib/AnyEvent/Twitter/Stream.pm b/lib/AnyEvent/Twitter/Stream.pm
use strict;
use warnings;
use Getopt::Long;
use AnyEvent::Socket;
use AnyEvent::Handle;
use HTTP::Parser::XS qw(parse_http_request);
GetOptions(
Rate AnyEvent::Gearman::Client Gearman::Client::Async
AnyEvent::Gearman::Client 1435/s -- -60%
Gearman::Client::Async 3571/s 149% --
From e3d97037aafb701374c02bf5cd1a3d7e2454188c Mon Sep 17 00:00:00 2001
From: Daisuke Murase <typester@cpan.org>
Date: Wed, 26 Aug 2009 11:03:06 +0900
Subject: [PATCH] fixed a cleanup bug
---
lib/AnyEvent/Twitter/Stream.pm | 4 +-
t/cleanup.t | 62 ++++++++++++++++++++++++++++++++++++++++
2 files changed, 64 insertions(+), 2 deletions(-)
create mode 100644 t/cleanup.t
From e3d97037aafb701374c02bf5cd1a3d7e2454188c Mon Sep 17 00:00:00 2001
From: Daisuke Murase <typester@cpan.org>
Date: Wed, 26 Aug 2009 11:03:06 +0900
Subject: [PATCH] fixed a cleanup bug
---
lib/AnyEvent/Twitter/Stream.pm | 4 +-
t/cleanup.t | 62 ++++++++++++++++++++++++++++++++++++++++
2 files changed, 64 insertions(+), 2 deletions(-)
create mode 100644 t/cleanup.t
use strict;
use warnings;
use YAML;
use AnyEvent;
use AnyEvent::Run;
my $cv = AnyEvent->condvar;
my $w = AnyEvent::Run->new(
#!/usr/bin/perl
use strict;
use warnings;
use HTTP::Request::Common;
use AnyEvent::HTTP;
use AnyEvent::ReverseHTTP;
use Digest::SHA1 qw/sha1_hex/;
my $proxy_to = $ARGV[0] or die 'require proxy target';
use strict;
use warnings;
use FindBin::libs;
use Schema;
Schema->connect->create_ddl_dir;