---
- include: python.yml
- include: ruby.yml

- name: clone golang
  git: repo=https://go.googlesource.com/go
       version={{ go_version }}
       dest=~/.golang
       force=yes
       depth=1

- name: compile golang
  shell: creates=~/.golang/bin/go
         chdir=~/.golang/src
         ~/.golang/src/make.bash

- name: make R module dir
  file: path=~/.rlang/lib/ state=directory
- copy: src=Rprofile dest=~/.Rprofile
- copy: src=Renviron dest=~/.Renviron

# There's some issue here with the ldpath -- commenting out for now.
#- name: Download rust setup script
#  get_url: dest=/tmp/rustup.sh url=https://static.rust-lang.org/rustup.sh mode=0755
#- name: Install rust
#  shell: creates=~/.rustlang/bin/rustc /tmp/rustup.sh --verbose --yes --disable-sudo --prefix=~/.rustlang

- dnf: name={{ item }} state=latest
  name: install R and Haskell
  sudo: true
  with_items:
  - haskell-platform
  - R
  - autoconf
  - make
  tags:
    - packages
  when: ansible_distribution != 'RedHat'

---
- include: python.yml
- include: ruby.yml

- name: make R module dir
  file: path=~/.rlang/lib/ state=directory
- copy: src=Rprofile dest=~/.Rprofile
- copy: src=Renviron dest=~/.Renviron

# There's some issue here with the ldpath -- commenting out for now.
#- name: Download rust setup script
#  get_url: dest=/tmp/rustup.sh url=https://static.rust-lang.org/rustup.sh mode=0755
#- name: Install rust
#  shell: creates=~/.rustlang/bin/rustc /tmp/rustup.sh --verbose --yes --disable-sudo --prefix=~/.rustlang

- dnf: name={{ item }} state=latest
  name: install R, Go, and Haskell
  sudo: true
  with_items:
  - haskell-platform
  - R
  - autoconf
  - make
  - golang
  tags:
    - packages
  when: ansible_distribution != 'RedHat'

Use Fedora golang package instead
Use Fedora golang package instead
