Commit 47c76c14 authored by Jean-Francois Rey's avatar Jean-Francois Rey
Browse files

add provisioning mactex, r packages, xquartz

parent de2f1dde
Vagrant.configure("2") do |config|
config.vm.box = "GAEV/MacOS_Catalina"
config.vm.boot_timeout = 1200
config.vm.synced_folder "./", "/Volume/vagrant, disavled: true
config.vm.synced_folder ".", "/vagrant", disabled: true
# Configure Vagrant to use SSH
config.vm.communicator = "ssh"
......
#!/bin/bash
echo "Download and install MacTex"
curl -O http://mirror.ctan.org/systems/mac/mactex/MacTeX.pkg
sudo installer -package MacTex.pkg -target /
rm MacTex.pkg
#!/bin/bash
### List off systems pre-compiled libraries
declare -a listL=(
"cairo-1.14.12-darwin.17-x86_64.tar.gz"
"cairomm-1.11.2-darwin.17-x86_64.tar.gz"
"fftw-3.3.8-darwin.17-x86_64.tar.gz"
"fontconfig-2.13.1-darwin.17-x86_64.tar.gz"
"freetype-2.10.0-darwin.17-x86_64.tar.gz"
"gdal-3.1.1-darwin.17-x86_64.tar.gz"
"geos-3.8.1-darwin.17-x86_64.tar.gz"
"gsl-2.6-darwin.17-x86_64.tar.gz"
"icu-67.1-darwin.17-x86_64.tar.gz"
"jpeg-9-darwin.17-x86_64.tar.gz"
"libpng-1.6.37-darwin.17-x86_64.tar.gz"
"libpq-9.6.9-darwin.17-x86_64.tar.gz"
"pcre2-10.34-darwin.17-x86_64.tar.gz"
"pkgconfig-0.28-darwin.17-x86_64.tar.gz"
"proj-6.3.1-darwin.17-x86_64.tar.gz"
"qpdf-9.1.1-darwin.17-x86_64.tar.gz"
"readline-5.2.14-darwin.17-x86_64.tar.gz"
"sqlite3-3.32.3-darwin.17-x86_64.tar.gz"
"texinfo-6.7-darwin.17-x86_64.tar.gz"
"tiff-4.1.0-darwin.17-x86_64.tar.gz"
"udunits-2.2.24-darwin.17-x86_64.tar.gz"
"xml2-2.9.10-darwin.17-x86_64.tar.gz"
"zlib-system-stub.tar.gz"
)
for i in "${listL[@]}"
do
echo "Download and install $i"
curl -O "http://mac.R-project.org/libs-4/$i"
sudo tar fvxz "$i" -C /
rm $i
done
echo "Installing R packages"
echo "dir.create(Sys.getenv('R_LIBS_USER'), recursive=TRUE); \
.libPaths( c(Sys.getenv('R_LIBS_USER'), .libPaths()) ) ; \
install.packages(c( \
'deSolve', \
'sp', \
'rgeos', \
'fields', \
'MASS', \
'Matrix', \
'deldir', \
'pracma', \
'raster', \
'fftwtools', \
'mvtnorm', \
'rgdal', \
'sf', \
'splancs', \
'knitr', \
'rmarkdown', \
'testthat', \
'Rcpp', \
'RcppArmadillo', \
'fasterize', \
'roxygen2', \
'shiny', \
'htmltools', \
'shinydashboard', \
'ggplot2', \
'dplyr', \
'dbplyr', \
'DT', \
'magrittr', \
'devtools', \
'shinyjs', \
'stringi', \
'stringr', \
'jsonlite', \
'data.table', \
'htmlwidgets', \
'RSQLite', \
'BiocManager', \
'foreach', \
'doParallel', \
'mvtnorm', \
'mapdata', \
'proj4', \
'gstat', \
'automap', \
'RCALI', \
'rgenoud', \
'purrr' \
), \
dependencies=TRUE, \
repos='https://cran.biotools.fr')" > /tmp/install.R
Rscript /tmp/install.R
Rscript -e "BiocManager::install(c('Biostrings', ask=FALSE))"
Rscript -e "update.packages(ask=FALSE, repos='https://cran.biotools.fr')"
#!/bin/bash
echo "Downloading gfortran for catalina..."
curl -O https://github.com/fxcoudert/gfortran-for-macOS/releases/download/10.2/gfortran-10.2-Catalina.dmg
curl -LO https://github.com/fxcoudert/gfortran-for-macOS/releases/download/10.2/gfortran-10.2-Catalina.dmg
echo "Install gfortran"
hdiutil attach gfortran-10.2-Catalina.dmg
installer -package gfortran-10.2-Catalina.dmg -target /
sudo nstaller -package /Volume/gfortran*/gfortran.pkg -target /
hdiutil detach /Volume/gfortran*
rm gfortran-10.2-Catalina.dmg
echo "Downloading R-4.0 Nightly..."
curl -O https://mac.r-project.org/high-sierra/R-4.0-branch/R-4.0-branch.pkg
curl -LO https://mac.r-project.org/high-sierra/R-4.0-branch/R-4.0-branch.pkg
echo "Installing R"
installer -package R-4.0-branch.pkg -target /
sudo installer -package R-4.0-branch.pkg -target /
rm R-4.0-branch.pkg
echo "export PATH=$PATH:/usr/local/gfortran/bin" >> .bashrc
echo "export PATH=/usr/local/gfortran/bin:\$PATH" >> ~\.bashrc
echo "export PATH=/usr/local/gfortran/bin:\$PATH" >> ~\.zshrc
# to install :
#https://cran.r-project.org/doc/manuals/r-patched/R-admin.html#Other-libraries
#https://cran.r-project.org/doc/manuals/r-patched/R-admin.html#macOS
#!/bin/bash
echo "Downloading Xquartz"
curl -o https://dl.bintray.com/xquartz/downloads/XQuartz-2.7.11.dmg
hdiutil attach XQuartz-2.7.11.dmg
installer -package /Volume/xquartz*/xquartz.pkg -target /
hdiutil detach /Volume/xquartz*
rm XQuartz-2.7.11.dmg
......@@ -4,5 +4,16 @@
tasks:
- name: ping
ping:
- name: Install R and dependencies
script: files/install-r.sh
- name: Install R packages and dependencies
script: files/install-r-library.sh
- name: Install MacTex
script: files/install-mactex.sh
- name: Install Xquartz
script: files/install-xquartz.sh
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment