Skip to content

Instantly share code, notes, and snippets.

@jpwatts
Created March 12, 2010 17:55
Show Gist options
  • Save jpwatts/330571 to your computer and use it in GitHub Desktop.
Save jpwatts/330571 to your computer and use it in GitHub Desktop.
#!/bin/sh
APP_PATH=/Applications
APP_NAME=${APP_PATH}/Chromium.app
TMP_PATH=/tmp/update-chromium-$$
TMP_NAME=${TMP_PATH}/chrome-mac.zip
BASE_URL=http://build.chromium.org/buildbot/snapshots/chromium-rel-mac
REVISION=$(curl -s ${BASE_URL}/LATEST)
mkdir -p $TMP_PATH
curl -s -o $TMP_NAME ${BASE_URL}/${REVISION}/chrome-mac.zip
unzip -q $TMP_NAME -d $TMP_PATH
if [ -e $APP_NAME ]; then
rm -r $APP_NAME
fi
mv ${TMP_PATH}/chrome-mac/Chromium.app $APP_PATH
rm -r $TMP_PATH
echo "Now at r${REVISION}" | growlnotify -a Chromium -t "Updated Chromium.app"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment