- name: Get vim
  get_url: url=https://github.com/vim/vim/archive/v{{ version }}.tar.gz dest=/usr/src/vim-{{ version }}.tar.gz validate_certs=False
  become: yes

- name: Unarchive vim
  unarchive: src=/usr/src/vim-{{ version }}.tar.gz dest=/tmp copy=no
  become: yes

- name: Build vim
  shell: make chdir=/tmp/vim-{{ version }}
  become: yes

- name: Install vim
  shell: make install chdir=/tmp/vim-{{ version }}
  become: yes
  
- name: Copy vim config
  file: src={{ role_path }}/files/vimrc dest=~/.vimrc state=link force=yes

- name: Get vim
  get_url: url=https://github.com/vim/vim/archive/v{{ version }}.tar.gz dest=/usr/src/vim-{{ version }}.tar.gz validate_certs=False
  become: yes

- name: Unarchive vim
  unarchive: src=/usr/src/vim-{{ version }}.tar.gz dest=/tmp copy=no
  become: yes

- name: Configure vim
  shell: ./configure --enable-pythoninterp --with-python-config-dir=/usr/lib/python2.7/config-x86_64-linux-gnu chdir=/tmp/vim-{{ version }}
  become: yes

- name: Build vim
  shell: make chdir=/tmp/vim-{{ version }}
  become: yes

- name: Install vim
  shell: make install chdir=/tmp/vim-{{ version }}
  become: yes
  
- name: Copy vim config
  file: src={{ role_path }}/files/vimrc dest=~/.vimrc state=link force=yes

Add configure task to vim role
Add configure task to vim role
