faithfulgeek (owner)

Forks

Revisions

gist: 114428 Download_button fork
public
Public Clone URL: git://gist.github.com/114428.git
Embed All Files: show embed
update_google_chrome.sh #
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#!/bin/bash
 
set -e
 
BUILD_URL='http://build.chromium.org/buildbot/snapshots/sub-rel-mac/'
 
update_google_chrome() {
  get_latest_revision_number
  download_latest_revision
  extract_code
  install_chrome
  display_latest_changes
}
 
get_latest_revision_number() {
  LATEST=`curl $BUILD_URL/LATEST`
}
 
download_latest_revision() {
  (cd ~/src &&
    curl -O $BUILD_URL/$LATEST/chrome-mac.zip)
}
 
extract_code() {
  (cd ~/src &&
    unzip -qq chrome-mac.zip)
}
 
install_chrome() {
  (cd ~/src/chrome-mac &&
    cp -fr Chromium.app /Applications &&
    cd .. &&
    rm -rf chrome-mac)
}
 
display_latest_changes() {
  curl $BUILD_URL/$LATEST/changelog.xml
}
 
update_google_chrome