commit - 885824bf4f1842c2c295698d39cdf81b00fb3c8e
commit + a47480acc4462f87f4fb9668611db99adbfbf14e
blob - 764405fa352780deed90dead9e759fa9a3d41f11
blob + ce4e00d8317328ee3665927a6ab9b370f19f3057
--- roles/workstation/tasks/main.yml
+++ roles/workstation/tasks/main.yml
- name: setup office
import_tasks: setup_office.yml
+
+- name: setup vim
+ import_tasks: setup_vim.yml
blob - /dev/null
blob + 84e6028757e5c699956a82c2d130dc02dcddaa30 (mode 644)
--- /dev/null
+++ roles/workstation/tasks/setup_vim.yml
+---
+
+- name: ensure package vim is installed
+ become: yes
+ become_method: doas
+ when: ansible_os_family == "OpenBSD"
+ openbsd_pkg:
+ name: "{{item}}"
+ state: present
+ with_items:
+ - vim--gtk2-perl-python-ruby
+
+- name: create vim bundle directory
+ file:
+ path: "{{ansible_env.HOME}}/.vim/bundle"
+ owner: '{{ansible_user_id}}'
+ group: wheel
+ mode: 0755
+ state: directory
+
+- name: clone vundle
+ become: true
+ become_user: '{{ansible_user_id}}'
+ git:
+ repo: https://github.com/VundleVim/Vundle.vim
+ dest: '{{ansible_env.HOME}}/.vim/bundle/Vundle.vim'
+ update: no
+
+- name: install vim plugins
+ command: su - '{{ansible_user_id}}' -c "vim -E -s -c 'source ~/.vimrc' -c PluginInstall -c qall -V"