Permalink
Browse files

Add ocaml install script for travis

  • Loading branch information...
polazarus committed Nov 27, 2013
1 parent f16950d commit 7d50a7d60d5b350a9367b74556d97f042f9c34eb
Showing with 19 additions and 0 deletions.
  1. +19 −0 .travis-ocaml.sh
View
@@ -0,0 +1,19 @@
case "$OCAML_VERSION" in
''|4|4.1|4.01|4.01.0) ppa=avsm/ocaml41 ;;
4.0|4.00|4.0.1|4.00.1) ppa=avsm/ocaml40 ;;
3|3.12|3.12.1) ppa=avsm/ocaml312 ;;
*) echo "Unknown ocaml version: $OCAML_VERSION"; exit 1 ;;
esac
case "$OPAM_VERSION" in
''|1|1.1|1.1.0) ppa=$ppa+opam11 ;;
1.0|1.0.0) ppa=$ppa+opam10 ;;
*) echo "Unknown opam version: $OPAM_VERSION"; exit 1;;
esac
sudo add-apt-repository -y ppa:$ppa
sudo apt-get update -qq
sudo apt-get install -qq ocaml-nox ocaml-native-compilers opam
opam init -y
eval `opam config env`

0 comments on commit 7d50a7d

Please sign in to comment.