java.sh 274 B

123456789
  1. #!/bin/bash
  2. # TODO include a check before we do all this, because it's
  3. # annoyingly slow to run apt-get if we don't need to
  4. # First remove java6
  5. sudo apt-get remove -y --purge openjdk-6-jre openjdk-6-jre-headless
  6. # Then install java7
  7. sudo apt-get install -y openjdk-7-jdk