# install.rb: Install script for ruby files. # $Id: install.rb,v 1.1.1.1 2003/04/24 18:23:11 komatsu Exp $ # # Copyright (C) 2002 Hiroyuki Komatsu # All rights reserved. # This is free software with ABSOLUTELY NO WARRANTY. # # You can redistribute it and/or modify it under the terms of # the GNU General Public License version 2. # require 'rbconfig' targets = ARGV install_path = (ENV['RUBY_SITEDIR'] or Config::CONFIG["sitedir"]) install_command = 'install -v -c' targets.each {|target| $stderr.puts "#{install_command} -m 644 #{target} #{install_path}/#{target}" `#{install_command} -d \`dirname #{install_path}/#{target}\`` `#{install_command} -m 644 #{target} #{install_path}/#{target}` }