Subj : files.bbs to .htaccess To : All From : andrew clarke Date : Sat Feb 15 2003 01:13 pm * Crossposted in area linux_bbs, linux, unix This may be useful for UNIX people ("ooh, look mummy, it's the UNIX people!") running BBSes. This morning I wrote a script to extract file_id.diz from zip files and add them to a files.bbs: #!/bin/sh for i in *; do echo -n $i >> files.bbs echo -n " " >> files.bbs unzip -Cap $i file_id.diz | tr "\n" " " >> files.bbs echo >> files.bbs done I also wrote a script to convert files.bbs to .htaccess format, for use with Apache. #!/bin/sh awk '{ filename = $1; $1 = ""; sub(" ", ""); printf "AddDescription \"%s\" %s\n", $0, filename }' < files.bbs | tee .htaccess Which means that any files located in autoindexed directories (directories without a default index.html or equivalent) on my web server will now have their own descriptions. Unfortunately long descriptions don't word-wrap, but I can't think of a good solution for that yet. You'll probably need to edit the default httpd.conf for this to work (changing the OptionsOverride and DescriptionWidth options, from memory). -- mail@ozzmosis.com --- Msged/NT 6.1.1 * Origin: Blizzard of Ozz, Mt Eliza, Victoria, Australia (3:633/267.1) .