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
// ==UserScript== | |
// @name hatena diarylist otsune mode | |
// @namespace http://rails2u.com/ | |
// @description 観測範囲が狭い人向け | |
// @include http://d.hatena.ne.jp/diarylist | |
// ==/UserScript== | |
(function() { | |
const CONTAINER_XPATH = '//div/ul[@class="list-plain"]'; | |
const LIST_XPATH = '//div/ul[@class="list-plain"]/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
project :test => :shoulda, :renderer => :haml, :stylesheet => :sass, :script => :jquery, :orm => :activerecord | |
#default routes | |
APP_INIT = <<-APP | |
get "/" do | |
"Hello World!" | |
end | |
get :about, :map => '/about_us' do | |
render :haml, "%p This is a sample blog created to demonstrate the power of Padrino!" |
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 | |
# -*- coding: utf-8 -*- | |
require 'logger' | |
=begin | |
WHATIS | |
* ping monitoring once every 30 secs |
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 'tweetstream' | |
require 'boxcar_api' | |
SETTINGS = { | |
:key => 'xyz', # Provider Key | |
:secret => 'xyz', # Provider Secret | |
:tweeter => 'macrumorslive' # Whom we'll be following on Twitter | |
:tweeter_id => 1581511, # The tweeter's user id (check their RSS feed) |
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
;; -*- mode: Emacs-Lisp; coding: utf-8-unix -*- | |
;;; migemo.el - Japanese incremental search trough dynamic pattern expansion | |
;; $Id: migemo.el.in,v 1.8 2006/09/22 08:43:33 shirai Exp $ | |
;; Copyright (C) Satoru Takabayashi | |
;; Author: Satoru Takabayashi <[email protected]> | |
;; Keywords: | |
;; This file is free software; you can redistribute it and/or modify |
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
// ==UserScript== | |
// @name A smart dashboard have my id | |
// @namespace http://mitukiii.jp/ | |
// @description TumblrのDashboardで自分からReblogされた/自分のidを含んだpostを折り畳むスクリプト | |
// @include http://www.tumblr.com/* | |
// @include https://www.tumblr.com/* | |
// ==/UserScript== | |
(function() { | |
var my_id = document.querySelector('#user_channels a') |
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 GenericsSample2 { | |
/** Parser */ | |
public static abstract class Parser<M extends Model<M>> { | |
public abstract M parse(); | |
} | |
/** Model */ | |
public static abstract class Model<M extends Model<M>> {} | |
/** UserParser */ | |
public static class UserParser extends Parser<UserModel>{ |
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
# Setting up a local solr instance on a mac | |
# install solr with homebrew | |
brew install solr | |
# create the base solr index directory | |
mkdir -p /data/solr | |
# make sure you can write to the solr logs | |
sudo chown -R `whoami` /usr/local/Cellar/solr/ |
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 | |
username="__USERNAME__" | |
password="__PASSWORD__" | |
filter="track=$1" | |
url="http://stream.twitter.com/1/statuses/filter.json" | |
curl -s --data-urlencode $filter $url -u$username:$password | perl -CIO -MJSON::Any -ne 'my $j=JSON::Any->new;while(<>){eval{my $t=$j->decode($_);printf("@%-15s: %s\n",$t->{user}->{screen_name},$t->{text}); };}' |
OlderNewer