e$B!!$5$5$@$G$9!%e(B
e$B!!0J2<$N$h$&$K!$e(B-v e$B$de(B -w e$BIU$-$Ne(B ruby e$B$Ge(B erb
e$B$re(B require e$B$9$k$H!$e(B"coding:
…" e$B$N>l=j$,0c$&$h!$$H$$$&7Y9p$,=P$^$9!%e(B
$ cat test.rb
require ‘erb’
$ /tmp/trunk/bin/ruby -v test.rb
ruby 1.9.2dev (2009-02-05 trunk 22076) [x86_64-linux]
test.rb:1: warning: encoding ‘UTF-8’ is ignored, valid only in the first
line except for shebang line.
test.rb:1: warning: encoding ‘Big5’ is ignored, valid only in the first
line except for shebang line.
e$B!!$3$l$O!$e(B2e$B$D$NLdBj$,$"$k$+$H;W$$$^$9!%e(B
(1) erb e$B$N@bL@$N%3%a%s%H$KH?1~$7$F7Y9p$r$7$F$$$ke(B
e$B!!$A$g$C$H8+$F$_$k$H!$e(B68
e$B9TL$K%3%a%s%HCf$N%5%s%W%k%3!<%I$H$7$Fe(B
# -- coding: UTF-8 --
e$B$H$$$&9T$,!$e(B72 e$B9TL$Ke(B
<%#-- coding: Big5 --%>
e$B$H$$$&9T$,$"$j$^$9!%$3$l$KBP$7$F$N7Y9p$8$c$J$$$+$H;W$$$^$9!%$A$g$C$H$d$je(B
e$B$9$.!)e(B
(2) require e$B$7$F$$$k9T$N7Y9p$H$7$F=P$F$$$ke(B
test.rb:1: warning: encoding ‘UTF-8’ is ignored, valid only in the first
line except for shebang line.
e$B$H!$e(Brequire
e$B$7$F$$$k9T$,7Y9p9T$H$7$FI=<($5$l$F$$$^$9!%B?J,!$e(Berb.rb:68 e$B$He(B
e$B$+$HI=<($7$F$/$l$?$[$&$,$$$$$H;W$$$^$9!%e(B
e$B!!e(B(1) e$B$O$I$&$+$J!$$H;W$$$^$9!%e(B(2)
e$B$O!$D>$7$?$[$&$,$$$$$s$G$O$J$$$+$H;W$$e(B
e$B$^$9!%e(B
(1) e$B$Ne(B ad-hoc e$B$J2r7h:v$H$7$F!$e(B=begin/=end
e$B$G0O$C$F$7$^$&$C$F$N$,e(B