Re: Help me write a fun script for my wallpaper project!
I installed a video card hoping that would help, but no good. With transparency, without, nothing.
Do you think you could help me input the lines that curl the taxonomic data from your lua into Luc's script?
I've tried doing it myself but while I can kind of grasp the shell script's language, the commands and symbols that follow the curl command are beyond my understanding, even after looking at the man file.
The relevant script is currently this:
#!/bin/bash
BASE_URL=http://macro.dokkyomed.ac.jp/mammal/en/specimen_no
TAXO_URL=http://animaldiversity.ummz.umich.edu/site/accounts/information
DIR="$HOME/img/walls"
ALIST=( `ls $DIR` )
FILE=${ALIST[$(($RANDOM % ${#ALIST[*]}))]}
feh --bg-fill $DIR/$FILE
#feh -x -N -B black -g 700x564 $DIR/$FILE
case $FILE in
DKY*) curl -silent $BASE_URL/${FILE:4:2}00.html ;;
*) curl --silent $BASE_URL/index_`echo ${FILE%%_*} | tr [:upper:] [:lower:]`.html ;;
esac | sed -n 's/^<li>[^>]*>'${FILE:4:4}'.*"italic">\([^<]*\).*/\1/p'and I know this is the relevant section:
curl -L 'http://animaldiversity.ummz.umich.edu/site/accounts/information/" .. animal .. ".html' | grep '<nobr>' | gawk -F'>' -v RS='<' 'RT{print $NF}' | sed '/^$/d' | sed ':a;N;$!ba;s/\\n//g'Last edited by rabidfox (2011-01-30 02:12:25)