Skip to content

Instantly share code, notes, and snippets.

@alfredxing
Created December 24, 2013 17:27
Show Gist options
  • Save alfredxing/8115948 to your computer and use it in GitHub Desktop.
Save alfredxing/8115948 to your computer and use it in GitHub Desktop.
Update Chromium automatically from the command line.

Automatically update Chromium (Windows with Bash)

Prerequisites:

  • wget

Installation:

  1. Create a file called version.txt in your Chromium/Application folder, with 0 as its contents.

Usage:

Just run the script!

Feel free to fork and adapt to the other OS's (shouldn't be too hard, you'll just need to unzip)!

#!/bin/bash
cd ~/AppData/Local/Chromium/Application
a=$(cat version.txt)
b=$(wget -qO- http://commondatastorage.googleapis.com/chromium-browser-snapshots/Win/LAST_CHANGE)
if (( $b > $a )); then
printf "Update available, downloading...\n\n"
echo $b > version.txt
cd ~/Downloads/Setup
wget http://commondatastorage.googleapis.com/chromium-browser-snapshots/Win/$b/mini_installer.exe -O mini_installer.exe
chmod +x mini_installer.exe
printf "\nInstalling..."
./mini_installer.exe
printf "\n"
echo Done!
else
echo Up to Date!
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment