I've looked at a couple different options out there and hadn't found a whole lot. I really like the direction UniUploader was going in, but it's still a client application with more features than what I was looking for.
Overall their Windows implementation is great, but caches your WoW information which makes a few people reluctant to use it (apparently this is to automatically launch WoW for you). The Java interface is cumbersome, doesn't work consistently and requires a version of Java not yet available to Mac OS X.
I then discovered a posting by ScratchMonkey, illustrating the use of cURL to post information to the "update.php" URL on the guild server:
http://www.wowroster.net/Forums/viewtop ... html#16139
For now, anyone looking to do this on Mac OS X can use the following, provided they have CURL already installed (included with Mac OS X).
CURL can be found at: http://curl.haxx.se/
Simply copy the contents into a file named "cp-update.sh" (be sure to use chmod +x cp-update.sh):
- Code: Select all
#!/bin/sh
WOW_ACCOUNT=YourWowAccountName
WOW_ROOT="/Applications/World of Warcraft"
UPDATE_URL=http://guild.site.org/roster/update.php
UPDATE_FILE=/tmp/CharacterProfiler.lua.gz
UPDATE_OUTPUT=/tmp/cp-update.html
echo
echo -=[ `date`
echo
echo -=[ Compressing character information...
if [ -f ${UPDATE_FILE} ] ; then
rm -rf ${UPDATE_FILE}
fi
gzip --stdout "${WOW_ROOT}/WTF/Account/${WOW_ACCOUNT}/SavedVariables/CharacterProfiler.lua" > ${UPDATE_FILE}
if [ -f ${UPDATE_FILE} ] ; then
echo
echo " done."
else
echo " ERROR: Unable to create update package (${UPDATE_FILE}), please try again."
exit
fi
echo
echo -=[ Uploading character information to ${UPDATE_URL}...
echo
curl -F CharacterProfiler=@${UPDATE_FILE} -F submit=Upload ${UPDATE_URL} -o ${UPDATE_OUTPUT}
if [ -f ${UPDATE_OUTPUT} ] ; then
echo
echo " response received from server."
else
echo
echo " ERROR: Output file not created (${UPDATE_OUTPUT}), please try again."
exit
fi
echo
echo -=[ Results...
echo
grep "Updating Character" ${UPDATE_OUTPUT} |grep "<strong>" | sed -e "s/<[^>]*>//g" | sed -e "s/^Updating/ Updated/g"
echo
This will produce the following output (which can be piped to a logfile):
- Code: Select all
$ ./cp-update.sh
-=[ Thu Sep 27 18:35:49 EDT 2007
-=[ Compressing character information...
done.
-=[ Uploading character information to http://guild.site.org/roster/update.php...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 112k 0 13623 100 98k 3571 26500 0:00:03 0:00:03 --:--:-- 28207
response received from server.
-=[ Results...
Updated Character [Spike]
Updated Character [Faye]
Updated Character [Jet]
Updated Character [Edward]
From here I hope to write a small app for basic functionality which will do the following:
- Run entirely in the background with minimal system resources
- Invoke update after recognizing WoW has exited
- Monitor for changes to the CharacterProfile.lua (timestamp or hash)
- Allow multiple accounts to be configured (or automatically scan)
- Attempt to be cross-platform
- XML debug option to allow user to copy and paste into an HTML form for problem resolution
This is partially implemented in both a shell-script and Perl for a prototype, while testing options for either single Java or multiple .NET / Cocoa / cron implementations.
Any ideas or suggestions would be appreciated.