Started to split tasks into roles
This commit is contained in:
parent
10088f03c7
commit
8e6e03d55c
6 changed files with 125 additions and 91 deletions
33
roles/neovim/tasks/main.yaml
Normal file
33
roles/neovim/tasks/main.yaml
Normal file
|
@ -0,0 +1,33 @@
|
|||
---
|
||||
- name: install required packages
|
||||
package:
|
||||
name:
|
||||
- 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:
|
||||
chdir: "{{ account.home }}/.dotfiles/nvim"
|
||||
cmd: ./install.sh
|
||||
creates: "{{ account.home }}/.config/nvim/init.vim"
|
||||
|
||||
- name: install nvim plugins
|
||||
become_user: "{{ account.name }}"
|
||||
shell:
|
||||
cmd: nvim +PlugInstall +PlugUpdate +qall
|
||||
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue