ansible-machine-setup/roles/neovim/tasks/main.yaml

36 lines
870 B
YAML
Raw Normal View History

2020-05-31 10:17:10 +00:00
---
- name: install required packages
package:
name:
2020-06-21 17:58:45 +00:00
- python3
- python-pynvim
2020-05-31 10:17:10 +00:00
- neovim
- ripgrep
state: latest
- name: create nvim plugin directory
become_user: "{{ account.name }}"
file:
path: "{{ account.home }}/.local/share/nvim/site/autoload/"
state: directory
- name: install vim-plug
become_user: "{{ account.name }}"
get_url:
url: https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim
dest: "{{ account.home }}/.local/share/nvim/site/autoload/plug.vim"
- name: install nvim config
become_user: "{{ account.name }}"
shell:
2020-05-31 10:52:20 +00:00
chdir: "{{ dotfiles }}/nvim"
2020-05-31 10:17:10 +00:00
cmd: ./install.sh
creates: "{{ account.home }}/.config/nvim/init.vim"
- name: install nvim plugins
become_user: "{{ account.name }}"
shell:
cmd: nvim +PlugInstall +PlugUpdate +qall