Skip to content

Instantly share code, notes, and snippets.

View znz's full-sized avatar

Kazuhiro NISHIYAMA znz

View GitHub Profile
@znz
znz / ruby-enterprise-1.8.6-20080810 installer failed on lenny(testing)
Created October 1, 2008 06:05
ruby-enterprise-1.8.6-20080810 installer failed on lenny(testing)
Welcome to the Ruby Enterprise Edition installer
This installer will help you install Ruby Enterprise Edition 1.8.6-20080810.
Don't worry, none of your system files will be touched if you don't want them
to, so there is no risk that things will screw up.
You can expect this from the installation process:
1. Ruby Enterprise Edition will be compiled and optimized for speed for this
system.
2. Ruby on Rails will be installed for Ruby Enterprise Edition.
http://groups.google.com/group/redmine-users-ja/browse_thread/thread/6ca8cfb88541e254/40dcd8d66de85a31?#40dcd8d66de85a31
の文字化け対応パッチが改行とかの問題でそのままだと当てられない。
diff -r 23aa8d1c4bcf -r d7daa8217d67 app/controllers/hoge_controller.rb
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/app/controllers/hoge_controller.rb Wed Nov 05 20:09:58 2008 +0900
@@ -0,0 +1,10 @@
+class HogeController < ApplicationController
+ session :off
+
+ def index
+ end
+
@znz
znz / check_regexp_n.rb
Created January 29, 2009 18:35
ripperで正規表現のnオプションの使用箇所を探す
#!/usr/bin/ruby
require 'ripper/filter'
class CheckRegexpN < Ripper::Filter
def on_regexp_end(token, data)
if /n/ =~ token
puts "#{data}:#{lineno}:#{token}"
end
data
@znz
znz / gist:104842
Created May 1, 2009 03:12
rcodetoolsの設定例
(setq load-path
(cons "~/.emacs.d/site-lisp/elisp" load-path))
(require 'auto-complete)
(setq-default ac-sources '(ac-source-abbrev ac-source-words-in-buffer))
(global-auto-complete-mode t)
(setq ac-auto-start 3)
(add-hook
'emacs-lisp-mode-hook
(lambda ()
(setq ac-sources '(ac-source-words-in-buffer ac-source-symbols))))
@znz
znz / configure.log
Created May 12, 2009 12:20
OpenSolarisでruby-1.9.1-p129
checking build system type... i386-pc-solaris2.11
checking host system type... i386-pc-solaris2.11
checking target system type... i386-pc-solaris2.11
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
@znz
znz / update-ooopackages-jaooo-recent-announce.rb
Created May 18, 2009 08:46
OpenOffice.org日本語プロジェクトの公式ニュースの抜粋とRSS生成
#!/usr/bin/ruby1.8 -Ku
# -*- coding: utf-8 -*-
=begin
= jaooo news list with rss
== usage
$ mkdir cache
$ mkdir out
$ ruby update-ooopackages-jaooo-recent-announce.rb
or
@znz
znz / daemon-in-terminal.rb
Created May 27, 2009 10:04
端末上で動くプログラムを通知スペースに入れる(Ruby/VTE依存)
#!/usr/bin/ruby1.8 -Ku
# -*- coding: utf-8 -*-
=begin
= run daemon in terminal
== usage
$ daemon-in-terminal.rb -- some-command [command arguments...]
* left click tray icon: toggle terminal
* right click tray icon: show menu
@znz
znz / .gitignore
Created August 12, 2009 17:12
Sequelを使ったときのテストがうまく書けない
memo.db
@znz
znz / bluescreen-boot-from-hd0-2.txt
Created September 10, 2009 09:15
BSODの時のメッセージ
A problem has been detected and windows has been shut down to prevent damage to your computer.
If this is the first time you've seen this Stop error screen,
restart your computer. If this screen appears again, follow
these steps:
Check for viruses on your computer. Remove any newly installed
hard drives or hard drive controllers. Check your hard drive
to make sure it is properly configured and terminated.
Run CHKDSK /F to check for hard drive corruption, and then