wrapper script to allow reading *.maff
Plmalternate Plmalternate <[email protected]>
| Newsgroups | gmane.comp.web.dillo.devel |
|---|---|
| Message-ID | <CAB2o_TF0pYO+CNxZ-WUV671scBZrGLGjxg2ML3Zg5y2qPvY+ug@mail.gmail.com> |
Some of y'all might find this useful. If you put it in your path, you can invoke it "dill filename" or make it the default ap for maffs or regular htm(l)s for that matter. It lets Dillo read the Mozilla Archive File Format (*.maff) files. Maffs are pretty nice - if you haven't played with them you might like to try it. Here is the body of the file if you find that more convenient than the attachment: #!/bin/bash # if the argument ends in ".maff" if [ "$(echo "$1" | rev | cut -c1-5 | rev)" = ".maff" ]; then DIR="/tmp/dillo_maff_unzpped/$(date +%s%N)" mkdir -p "$DIR" unzip "$1" -d "$DIR" SUBDIR="$(ls "$DIR")" dillo "$DIR/$SUBDIR/index.html" || dillo "$DIR/$SUBDIR/index.htm" rm -r "$DIR" else dillo "$1" fi _______________________________________________ Dillo-dev mailing list [email protected] http://lists.dillo.org/cgi-bin/mailman/listinfo/dillo-dev
dill
(application/octet-stream, 317 B) - not displayed