I often am working on a variety of WordPress, BuddyPress, and BBPress projects and enjoy working from a lot of not internet connected locations such as trains, buses, parks and the occasional rooftop. As such it’s very handy for me to a local version of PHPXref documents for the current trunk of these products. I’ve written a handy bash script to handle this for me.
# define locations
# check our internet connection
wget -q –tries=10 –timeout=5 http://core.svn.wordpress.org/trunk/ -O /tmp/wordpress.svn &> /dev/null
if [ ! -s /tmp/wordpress.svn ];then
# Remove old version
rm -r $PHPXREFLOCATION/output/*
# SVN up each piece
# Build our new phpxref
#remove the tmp file so it’s not there for next time
I have a cron set up to run this at a few intervals that are least likely to bother me (currently 5am and 4pm). I hope this script helps you out. If you have a similar or better one, please let me know.