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 project was moved to https://github.com/tdtds/kindlizer |
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
| // ==UserScript== | |
| // @name play on tumblr | |
| // @namespace tag:[email protected],2008-04-03:/coderepos.org | |
| // @description play current image or video on tumblr dashboard with 'ENTER' key. open notes with 'h' key. like it with 'l' key. if won't work, pray on tumblr! | |
| // @include http://www.tumblr.com/dashboard* | |
| // @include http://www.tumblr.com/show/* | |
| // @include http://www.tumblr.com/tumblelog/* | |
| // @include http://www.tumblr.com/tagged/* | |
| // ==/UserScript== |
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
| // http://nanto.asablo.jp/blog/2005/10/24/118564 の 擬似的なnew演算子の動作 | |
| F.applyNew([param1, param2]); // == new F(param1, param2) をやったとき | |
| // => this : F , args : [param1, param2] | |
| Function.prototype.applyNew = function (args) { | |
| var that = this;// 解説的にややこしいのでthatにする | |
| var Constructor = function () {};//空のオブジェクト作る | |
| Constructor.prototype = this.prototype;// prototypeの設定をする | |
| var instance = new Constructor();// instanceを作る | |
| var result = that.apply(instance, args); |
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
| // ------------------------- | |
| // TabGroup&Tabの定義と表示 | |
| // ------------------------- | |
| // | |
| // ※余談ですが、SplitViewをコンテナとしてTabGroupを持つ事が出来ません。 | |
| // そういう構成を組みたい場合はwin3.jsサンプルのようにViewを分割し、 | |
| // 左側のViewにTabGroupをセットするようなやり方になります。 | |
| // | |
| var tabGroup = Ti.UI.createTabGroup(); | |
| tabGroup.addTab(Ti.UI.createTab({ |
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/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}); };}' |
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
| # 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 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
| 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 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
| // ==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 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
| ;; -*- 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 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 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) |