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
require 'rexml/document' | |
require 'cgi' | |
require 'open-uri' | |
def get_itcal(terma) | |
raise ArgumentError, "terma is not integer" unless terma.kind_of?(Integer) | |
raise ArgumentError, "terma is not 0-4" if terma > 4 || terma < 0 | |
terms = [86400,259200,604800,1209600,25992000] | |
#terms = [86400,259200,25992000,0] | |
term = terms[terma] | |
# 1day = 0 |
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
# -*- coding: utf-8 -*- | |
# Googeous bot | |
# Author: gigi-net | |
# Modified by: Sora Harakami | |
require 'rubygems' | |
require 'rubytter' | |
require 'rss' | |
twitter_id ="googeousbot" |
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
autoload -U colors | |
colors | |
PROMPT="%B%{$fg[cyan]%}%n@%m: [%~] %b%{$reset_color%} | |
%#%f%s " | |
PROMPT2='%B%_%(?.%f.%S%F)%b | |
%#%f%s ' | |
SPROMPT="%r is correct? [n,y,a,e]: " | |
autoload -U compinit; compinit | |
~ | |
~ |
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 | |
" | |
execute 'help' getline(1) | |
.,/\*\S\+\*$/?\S?print | |
qa! | |
" | |
require 'rubygems' | |
require 'json' | |
require 'cgi' |
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
--- parse.y.orig 2010-01-13 15:08:58.975313692 +0900 | |
+++ parse.y 2010-01-13 14:33:40.191308036 +0900 | |
@@ -636,6 +636,7 @@ | |
keyword_ensure | |
keyword_end | |
keyword_if | |
+ keyword_myif | |
keyword_unless | |
keyword_then | |
keyword_elsif |
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
<?xml version="1.0" encoding="utf-8"?> | |
<mx:WindowedApplication xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute"> | |
<mx:Script> | |
<![CDATA[ | |
private function calc():void { | |
var ans:Number; | |
var a:Number = Number(arg1.text); | |
var b:Number = Number(arg2.text); | |
switch(kigo.text) { |
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
諸君 私は補完が好きだ | |
諸君 私は補完が好きだ | |
諸君 私は補完が大好きだ | |
手動補完が好きだ 自動補完が好きだ インテリセンスが好きだ 部分マッチが好きだ | |
シェルが好きだ 予測補完が好きだ オムニ補完が好きだ | |
Vimで Emacsで zshで | |
Visual Studioで ATOKで Eclipseで |
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
# If g is not loaded yet, try to load. | |
# Then if LoadError isn't raised run g. | |
module Kernel | |
def g(*args, &block) | |
begin | |
require 'g' | |
rescue LoadError; else | |
Kernel.g(*args, &block) | |
end |
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
class FewConfig < Hash | |
include ::Singleton | |
def self.method_missing(n,*a) | |
self.instance.__send__(n,*a) | |
end | |
def method_missing(n,*a) | |
case n.to_s | |
when /=$/ | |
self[n.to_s.gsub(/=$/,'').to_sym]=a[0] |
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
hi |