As configured in my dotfiles.
start new:
tmux
start new with session name:
module GaRuby | |
class GaRubyError < StandardError ; end | |
class Gene | |
attr_acessor :data,:value | |
def initialize(gen_num=nil) | |
@value=0 | |
if block_given? | |
@data=Array.new(gen_num){yield} | |
else |
diff --git a/Gemfile b/Gemfile | |
index eedb107..6d26f41 100644 | |
--- a/Gemfile | |
+++ b/Gemfile | |
@@ -8,7 +8,7 @@ source "http://rubygems.org" | |
group :development do | |
gem "rspec", "~> 2.8.0" | |
gem "rdoc", "~> 3.12" | |
- gem "bundler", "~> 1.0.0" | |
+ gem "bundler", ">= 1.0.0" |
require 'ruby_gntp' | |
Earthquake.init do | |
output do |item| | |
next unless item["_stream"] | |
if item["text"] | |
GNTP.notify({:app_name => "earthquake",:title => item["user"]["screen_name"],:text => item["text"],:icon => item["user"]["profile_image_url"]})#icon_path(user.screen_name, user.profile_image_url) }) | |
#if /@sifikinoko(?:[\s:]|$)/ =~ item["text"] | |
# system{ | |
# 'notify-send', | |
# '--urgency','critical', |
As configured in my dotfiles.
start new:
tmux
start new with session name:
# | |
# Install: | |
# install https://github.com/github/gollum | |
# in /srv/wiki do a git init | |
# add this script to /etc/init/gollum.conf | |
# | |
# Usage: | |
# start/stop/restart gollum | |
# |
" Z - cd to recent / frequent directories | |
command! -nargs=* Z :call Z(<f-args>) | |
function! Z(...) | |
let cmd = 'fasd -d -l -e printf' | |
for arg in a:000 | |
let cmd = cmd . ' ' . arg | |
endfor | |
let pathes = split(system(cmd),"\n") | |
for i in range(0,len(pathes)-1) | |
echo i ." " . pathes[i] |
" Vim global plugin for working with ROS | |
" Maintainer: Michael Styer <michael@styer.net> | |
" Fixed by : Fujii Shohei <fujii.shohei@gmail.com> | |
" Helper commands | |
function! s:RosDecodePath(path) | |
let rosname = "" | |
let reldir = "" | |
let rosdir = "" | |
let last = "" |
# -*- coding: utf-8 -*- | |
# vim: filetype=ruby | |
config.token_file = "~/.termtter/token" | |
#config.dmsg_permission = true | |
config.update_interval = 30 | |
config.timeout = 60 | |
#config.retry = 3 | |
#config.enable_ssl = true |
# -*- coding: utf-8 -*- | |
config.filters.mute.set_default(:words, []) | |
config.filters.mute.set_default(:users, []) | |
module Termtter::Client | |
register_hook( | |
:name => :mute, | |
:point => :filter_for_output, | |
:exec => lambda { |statuses, event| |
[ $# -eq 0 ] && echo "No arguments" && exit 0 | |
value="$(perl -MURI::Escape -e 'print uri_escape($ARGV[0]);' "$*")" | |
curl "http://eow.alc.co.jp/${value}/UTF-8/" 2>/dev/null | w3m -T text/html | sed -e "1,36d" | less | |
# this script needs curl,w3m,liburi-perl. | |
# If you use ubuntu,try this command | |
# sudo aptitude install curl w3m liburi-perl |