2007-06-19から1日間の記事一覧

cut コマンドの実装

ruby で組んでみた。対応しているのは、-f オプションと -d オプションのみ。 それ以外は使わないので。 require 'optparse' class Fields def initialize(rule) @ranges = [] rule.split(",").each do |v| if /^(\d+)?(-)?(\d+)?$/ =~ v b = $1 ? $1.to_i :…

etch へのアップグレード2

/etc/init.d/ntpdate がなくなっていた。 ntpdate をcron で定期実行していたのだが、 気がつくと ntp デーモンが動いていた・・・。ntp を使うために /etc/ntp.conf の設定を行った。