A stab at fixing the make-cgit list script.

This commit is contained in:
Ralph Bean 2015-12-17 16:13:12 +00:00
parent c6783d0391
commit 8d70839c02

View file

@ -6,16 +6,17 @@
# Looking for git repos.
#
newfile=`mktemp`
target=/srv/git/repositories
ls > $newfile
cd /srv/git/repositories/
for d in `ls`; do
if [ ! -L $d ] && [ -d $d ]; then
for f in `ls $d`; do
echo $d/$f >> $newfile;
ls $target > $newfile
for d in `ls $target`; do
if [ ! -L $target/$d ] && [ -d $target/$d ]; then
for f in `ls $target/$d/`; do
echo "$d/$f" >> $newfile;
done;
fi;
done;
mv -Z $newfile /srv/git/pkgs-git-repos-list
chown apache:apache /srv/git/pkgs-git-repos-list
chmod 644 /srv/git/pkgs-git-repos-list