File: install.rb

package info (click to toggle)
libmp3tag-ruby 1.0-3
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 76 kB
  • ctags: 52
  • sloc: ruby: 352; makefile: 6
file content (27 lines) | stat: -rwxr-xr-x 501 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/usr/bin/env ruby
require "rbconfig"
require "ftools"
include Config

RV = File.join(CONFIG['sitedir'], CONFIG['MAJOR'] + '.' + CONFIG['MINOR'])
DSTPATH = RV

FILES = %w(mp3tag.rb)
MANFILES = %(mp3tag.3)

File.mkpath DSTPATH, true

begin
  FILES.each { |name|
    File.install name, File.join(DSTPATH), 0644, true
  }
  MANFILES.each {
    |name|
    File.install name, File.join(CONFIG['mandir'], 'man3'), 0644, true
  }
rescue
  puts 'install failed!'
  puts $!
else
  puts 'install succeed!'
end