Skip to content

Instantly share code, notes, and snippets.

View alpicola's full-sized avatar

Ryo Tanaka alpicola

View GitHub Profile
#!/usr/bin/env ruby
SOI = "\xff\xd8"
APP0 = "\xff\xe0"
DQT = "\xff\xdb"
DHT = "\xff\xc4"
SOF0 = "\xff\xc0"
SOS = "\xff\xda"
EOI = "\xff\xd9"
<?xml version='1.0'?>
<!DOCTYPE signatures SYSTEM "file://localhost/System/Library/DTDs/BridgeSupport.dtd">
<signatures version='1.0'>
<depends_on path='/System/Library/Frameworks/CoreFoundation.framework'/>
<depends_on path='/System/Library/Frameworks/SystemConfiguration.framework'/>
<depends_on path='/System/Library/Frameworks/Security.framework'/>
<cftype name='DCSDictionaryRef' type='^{__DCSDictionary=}'/>
<function name='DCSCopyTextDefinition'>
<arg type='^{__DCSDictionary=}'/>
<arg type='^{__CFString=}'/>
require 'ffi-ncurses'
class Tetris
Curses = FFI::NCurses
PIECES = [
[ # O
[[-1, 0], [0, 0], [-1, 1], [0, 1]]
],
[ # I
#!/usr/bin/env ruby
require 'twitter'
require 'yaml'
if ARGV.length != 1
puts 'usage: ./tweet.rb Hello!'
exit
end
#!/usr/bin/env ruby
require 'rubygems'
require 'mechanize'
require 'net/smtp'
require 'date'
require 'yaml'
require 'nkf'
FROM = '[email protected]'
// ==UserScript==
// @name Atomos Entry Management
// @namespace http://5ivestar.org/
// @include http://localhost:9292/*
// ==/UserScript==
var username = 'admin';
var password = 'password';
var style = document.createElement('style');
// ==UserScript==
// @name Atomos Entry Management
// @namespace http://5ivestar.org/
// @include http://localhost:9292/*
// @include http://localhost:9393/*
// ==/UserScript==
var username = 'admin';
var password = 'password';
// ==UserScript==
// @name Google Search Filter
// @description Selected web-sites aren't displayed from Google search result.
// @version 2.2.6
// @author Shinya
// @namespace http://www.code-404.net/
// @homepage http://userscripts.org/scripts/show/12643
// @include http://www.google.*/search*
// @require http://gist.github.com/3242.txt
// ==/UserScript==