Created
April 23, 2010 16:32
-
-
Save karbassi/376765 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Downloads and installs the latest version of Chromium onto your Mac OS X. | |
# Requires curl, unzip, and rsync. | |
set -eu | |
curl="/usr/bin/curl" | |
unzip="/usr/bin/unzip" | |
rsync="/usr/bin/rsync" | |
rm="/bin/rm" | |
mkdir="/bin/mkdir" | |
app=`basename $0` | |
tdir="${TMPDIR}/tmp.${app}.$$" | |
"${mkdir}" -p "${tdir}" | |
cd "${tdir}" | |
baseurl=http://build.chromium.org/buildbot/snapshots/chromium-rel-mac | |
echo "Fetching latest version..." | |
latest=`"${curl}" -q -s ${baseurl}/LATEST` | |
#echo "Fetching changelog..." | |
#"${curl}" -q "${baseurl}/${latest}/changelog.xml" | |
echo "Downloading to ${tdir}..." | |
"${curl}" -sq -Ochrome-mac.zip "${baseurl}/${latest}/chrome-mac.zip" | |
echo "Extracting..." | |
"${unzip}" -q chrome-mac.zip | |
echo "Installing ${latest}..." | |
"${rsync}" -a --delete-after "${tdir}"/chrome-mac/Chromium.app/ /Applications/Chromium.app/ | |
echo "${latest}" > /Applications/Chromium.app/Contents/version | |
echo "Cleaning up..." | |
"${rm}" -rf "${tdir}" | |
# EOF |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment