From 3b29a7bed8a2827b55ecba9eb352b3c108f61083 Mon Sep 17 00:00:00 2001 From: Sebastian Felis Date: Tue, 8 Aug 2017 13:57:12 +0200 Subject: [PATCH] Add support for a fixed revision In some cases a fixed revision of chromium is preferred, e.g. for building docker images. --- README.md | 11 +++++++++++ update.sh | 8 ++++++-- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 53f614e..4dcc1d0 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,13 @@ # chromium-latest-linux Scripts to download and run the latest Linux build of Chromium. + +## Usage + +Download and updates the latest build of Chromium + + $ ./update-and-run.sh + +Download a specific revision + + $ export REVISION=492595 + $ ./update-and-run.sh diff --git a/update.sh b/update.sh index 6730185..d3858e4 100755 --- a/update.sh +++ b/update.sh @@ -4,9 +4,13 @@ cd $(dirname $0) LASTCHANGE_URL="https://www.googleapis.com/download/storage/v1/b/chromium-browser-snapshots/o/Linux_x64%2FLAST_CHANGE?alt=media" -REVISION=$(curl -s -S $LASTCHANGE_URL) +if [ -z "$REVISION" ]; then + REVISION=$(curl -s -S $LASTCHANGE_URL) -echo "latest revision is $REVISION" + echo "latest revision is $REVISION" +else + echo "Using given revision $REVISION as latest revision" +fi if [ -d $REVISION ] ; then echo "already have latest version"