#!/bin/sh # # (c) Wed Nov 9 12:20:09 CET 2011 # spd_at_daphne.cps.unizar.es # Version: 0.1.2a # # Script to create stats page and song indexes for stream 0.1.0a "aTunes" # # Requires: # ImageMagick # gnuplot # # Uses: # music-list-by-date.sh # music-list-by-year.sh # music-atom.sh LANG=C . /usr/local/etc/stream.conf cd "${MAINDIR}" gnuplot << EOF set terminal png small set output "music-list-by-date.png" set label "Albums by date" set xlabel "Date" set ylabel "Albums" set xdata time set timefmt "%Y-%m-%d" set format x "%y/%m" #set xrange ["2007-12-01":"2009-12-31"] plot "< $HOME/usr/bin/music-list-by-date.sh" using 1:2 with lines title "" EOF gnuplot << EOF set terminal png small set output "music-list-by-year.png" set label "Albums by year" set xlabel "Year" set ylabel "Albums" set yrange [0:150] set boxwidth 0.8 set style fill solid 0.25 border plot "< $HOME/usr/bin/music-list-by-year.sh" using 2:1 with boxes title "" EOF cd $ROOT find 0* ? -type f -name \*mp3 -user spd -print > $IDX/songs.txt find 0* ? -type f -name \*mp3 \! -user spd -print > $IDX/canciones.txt cd "${MAINDIR}" convert -resize 50% music-list-by-date.png \ music-list-by-date_small.png convert -resize 50% music-list-by-year.png \ music-list-by-year_small.png ( cat << EOF
" music-list-diff.sh $PREV $CURRENT echo "" PREV=$CURRENT done cat <
Discos por año de publicación | Evolución del número de discos ordenados |
---|---|
|
|
Actualizado: `env LANG=es_ES date '+%d de %B, %Y'`
" >> index.html cat >> index.html << EOF EOF music-atom.sh