-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinstall.pl
executable file
·39 lines (34 loc) · 1004 Bytes
/
install.pl
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
32
33
34
35
36
37
38
#!/usr/bin/perl
############################################################
# install: the installer
#
# by eXerigumo Clanjor (哆啦比猫/兰威举), 2012.
# Licensed under GPLv2. ABSOLUTELY NO WARRANTY!
############################################################
# copy the wrapper
open FIN, "<src/brainsuck.pl" or die $!;
open FOUT, ">/usr/local/bin/brainsuck" or die $!;
while (<FIN>) { print FOUT }
close FIN;
close FOUT;
chmod 0755, "/usr/local/bin/brainsuck" or die $!;
# copy llbs, filtering out the debugging info
open FIN, "<src/llbs/llbs.pl" or die $!;
open FOUT, ">/usr/local/bin/llbs" or die $!;
while (<FIN>) {
s/^.*print STDERR.*[\n\r]*//g;
print FOUT;
}
close FIN;
close FOUT;
chmod 0755, "/usr/local/bin/llbs" or die $!;
# copy bs, filtering out the debugging info
open FIN, "<src/bs/bs.pl" or die $!;
open FOUT, ">/usr/local/bin/bs" or die $!;
while (<FIN>) {
s/^.*print STDERR.*[\n\r]*//g;
print FOUT;
}
close FIN;
close FOUT;
chmod 0755, "/usr/local/bin/bs" or die $!;