[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[plamo:22456] Re: drac
-
From:KOJIMA Mitsuhiro
-
Date:Fri, 23 Apr 2004 03:08:21 +0900 (JST)
- Subject: [plamo:22456] Re: drac
- From: KOJIMA Mitsuhiro <kojima@xxxxxxxxxxx>
- Date: Fri, 23 Apr 2004 03:08:20 +0900 (JST)
From: "KAMOSAWA, Masao" <yaegr@plamo.minidns.net>
Subject: [plamo:22453] Re: drac
Date: Fri, 23 Apr 2004 02:00:11 +0900
> ) 実際に動かすコマンドなんで,/usr/local/bin/make_list.sh になってます.
>
> ありがとうございます。anon ftp からでは見えませんでした。
> どちらかでちらりと見せていただけたら助かります。
そう大したものでもないのだけど,興味ある人が他にもいらっしゃるかと思っ
て,添付しておきます :-)
#!/bin/sh
src=$1
lastdir=`basename $src`;
vers=`echo $lastdir | sed "s/Plamo-//"`;
echo "checking Plamo-$vers "
if [ ! -d $src/contrib ]; then
echo "cannot find contribs. exit"
exit
fi
find $src -name "*~" -print -exec rm {} \;
find $src -name "work" -exec rm -rf {} \;
if [ -f $src/plamo/filelist.gz ]; then
modified=`find $src/plamo/ -name "*.tgz" -newer $src/plamo/filelist.gz`
else
modified="all"
fi
if [ ! "$modified" = "" ]; then
echo "modified files found in plamo. remaking md5sum & filelist"
echo "modified files : $modified"
echo "making md5sum..."
( cd $src/plamo ; md5sum */*.tgz > md5sum )
echo "making filelists..."
( cd $src/plamo ; ls */*.tgz | perl /usr/local/bin/makelist.pl | gzip > filelist.gz )
else
echo "no modifed files found in plamo"
fi
modified=`find $src/contrib -name "*.tgz" -newer $src/contrib/filelist.gz`
echo "$modified"
if [ ! "$modified" = "" ]; then
echo "making contrib/md5sum.."
( cd $src/contrib ; md5sum */*.tgz */*/*.tgz > md5sum )
echo "making contrib/filelists..."
( cd $src/contrib ; ls */*.tgz */*/*.tgz | perl /usr/local/bin/makelist.pl | gzip > filelist.gz )
else
echo "no modifed files found in contrib"
fi
#! /usr/bin/perl
use Cwd;
while(<>) {
chop;
(@path) = split(/\//,$_);
$file = pop(@path);
$dir = join '/', (@path);
print "+------------------------------------------------\n";
print "+ $dir/$file \n";
print "+------------------------------------------------\n";
$basedir = cwd();
chdir($dir) || die "Cannot chdir to $dir \n";
$tmpfile = "/tmp/.file$$";
system("tar tvzpf $file > $tmpfile");
open(FILE,"$tmpfile");
while(<FILE>) {
print;
}
close(FILE);
unlink $tmpfile;
chdir($basedir);
}
- References
-
- [plamo:22442] Re: drac, KOJIMA Mitsuhiro
- [plamo:22453] Re: drac, KAMOSAWA, Masao
[検索ページ]
[メール一覧]
Plamo ML 公開システム