File: install.pl

package info (click to toggle)
auto-pgp 1.04-1
  • links: PTS
  • area: contrib
  • in suites: hamm
  • size: 176 kB
  • ctags: 92
  • sloc: perl: 498; lisp: 452; makefile: 115; ansic: 103; sh: 87
file content (31 lines) | stat: -rw-r--r-- 643 bytes parent folder | download | duplicates (2)
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
28
29
30
31
# -* perl -*- script for installation
# args: actual-filename notional-thingumname type

# This file is COPYRIGHT - see the file COPYRIGHT
# in this directory.

require 'EDITME';

$actual= $ARGV[0];
eval '$destn= $config_i_'.$ARGV[1];
eval '$user= $config_'.$ARGV[2].'user';
eval '$group= $config_'.$ARGV[2].'group';
eval '$mode= $config_'.$ARGV[2].'mode';

if ($ARGV[2] eq 'man') {
    eval '$_= $config_l_'.$ARGV[1];
    $destn= "$config_i_mandir/$_.$config_i_manext";
}

$it= <<END
    cp $actual $destn && \\
    (chown $user $destn; \\
     chgrp $group $destn; \\
     true) && \\
    chmod $mode $destn
END
    ;

print $it;

exec $it;