Skip to content

Instantly share code, notes, and snippets.

View cho45's full-sized avatar

Satoh, Hiroh cho45

View GitHub Profile
use strict;
use warnings;
use Mac::AppleScript qw(RunAppleScript);
use Perl6::Say;
use FindBin;
my $me = "$0";
sub play {
my $script = <<"SCRIPT";
#!/usr/bin/env perl
use strict;
use warnings;
use Pod::Usage;
use Text::Markdown 'markdown';
use HTML::TreeBuilder;
use List::Util 'max';
#!perl
use v5.10;
use AnyEvent;
my $cv = AE::cv;
my @timers;
for my $num (@ARGV) {
$cv->begin;
push @timers, AE::timer $_, 0, sub {
say $num;
#!/usr/bin/env perl
use strict;
use warnings;
use Pod::Usage;
use Text::Markdown 'markdown';
use HTML::TreeBuilder;
use List::Util 'max';
@wakaba
wakaba / bookmarklet
Last active February 16, 2017 07:34
javascript:var s=document.createElement('script');s.src="https://gist.githack.com/wakaba/b90f120b2617afe5c2fc4d08d84e801f/raw/script.js";document.body.appendChild(s);void(0)
@tatsuru
tatsuru / mackerel-plugin-theschwartz.sh
Created December 19, 2014 10:27
Theschwartz job count plugin for Mackerel
#!/bin/bash
usage() {
echo "Usage: $0 [-m METRIC_NAME] [-u USER] [-p PASSWORD] [-d DATABASE] [-h]"
}
METRIC_NAME=theschwartz.count
DBUSER=root
DBPASS=
DATABASE=theschwartz