Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(200)

Side by Side Diff: pkg/dev_compiler/tool/get_chrome_canary.sh

Issue 2398843002: Workaround from Chromium breakage (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/bin/bash 1 #!/bin/bash
2 # 2 #
3 # Ensures the latest Chrome Canary is available, downloading it 3 # Ensures the latest Chrome Canary is available, downloading it
4 # if necessary. 4 # if necessary.
5 # 5 #
6 # Directory ~/.chrome/canary can safely be cached as the existing 6 # Directory ~/.chrome/canary can safely be cached as the existing
7 # version will be checked before reusing a previously downloaded 7 # version will be checked before reusing a previously downloaded
8 # canary. 8 # canary.
9 # 9 #
10 10
(...skipping 17 matching lines...) Expand all
28 CHROME_NAME=chrome-win32 28 CHROME_NAME=chrome-win32
29 CHROME_RELATIVE_BIN=chrome.exe 29 CHROME_RELATIVE_BIN=chrome.exe
30 else 30 else
31 echo "Unknown platform: $OSTYPE" >&2 31 echo "Unknown platform: $OSTYPE" >&2
32 exit 1 32 exit 1
33 fi 33 fi
34 34
35 readonly CHROME_CANARY_DIR=$HOME/.chrome/canary 35 readonly CHROME_CANARY_DIR=$HOME/.chrome/canary
36 readonly CHROME_CANARY_BIN=$CHROME_CANARY_DIR/$CHROME_NAME/$CHROME_RELATIVE_BIN 36 readonly CHROME_CANARY_BIN=$CHROME_CANARY_DIR/$CHROME_NAME/$CHROME_RELATIVE_BIN
37 readonly CHROME_CANARY_REV_FILE=$CHROME_CANARY_DIR/VERSION 37 readonly CHROME_CANARY_REV_FILE=$CHROME_CANARY_DIR/VERSION
38 readonly CHROME_REV=$(curl -s ${CHROME_URL}/LAST_CHANGE) 38 # FIXME(vsm): The latest chromium segfaults on travis and my local linux box.
39 # readonly CHROME_REV=$(curl -s ${CHROME_URL}/LAST_CHANGE)
40 readonly CHROME_REV=423167
39 41
40 function getCanary() { 42 function getCanary() {
41 local existing_version="" 43 local existing_version=""
42 if [[ -f $CHROME_CANARY_REV_FILE && -x $CHROME_CANARY_BIN ]]; then 44 if [[ -f $CHROME_CANARY_REV_FILE && -x $CHROME_CANARY_BIN ]]; then
43 existing_version=`cat $CHROME_CANARY_REV_FILE` 45 existing_version=`cat $CHROME_CANARY_REV_FILE`
44 echo "Found cached Chrome Canary version: $existing_version" 46 echo "Found cached Chrome Canary version: $existing_version"
45 fi 47 fi
46 48
47 if [[ "$existing_version" != "$CHROME_REV" ]]; then 49 if [[ "$existing_version" != "$CHROME_REV" ]]; then
48 echo "Downloading Chrome Canary version: $CHROME_REV" 50 echo "Downloading Chrome Canary version: $CHROME_REV"
49 rm -fR $CHROME_CANARY_DIR 51 rm -fR $CHROME_CANARY_DIR
50 mkdir -p $CHROME_CANARY_DIR 52 mkdir -p $CHROME_CANARY_DIR
51 53
52 local file=$CHROME_NAME.zip 54 local file=$CHROME_NAME.zip
53 curl ${CHROME_URL}/${CHROME_REV}/$file -o $file 55 curl ${CHROME_URL}/${CHROME_REV}/$file -o $file
54 unzip $file -d $CHROME_CANARY_DIR 56 unzip $file -d $CHROME_CANARY_DIR
55 rm $file 57 rm $file
56 echo $CHROME_REV > $CHROME_CANARY_REV_FILE 58 echo $CHROME_REV > $CHROME_CANARY_REV_FILE
57 fi 59 fi
58 } 60 }
59 61
60 getCanary >&2 62 getCanary >&2
61 63
62 echo $CHROME_CANARY_BIN 64 echo $CHROME_CANARY_BIN
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698