This repository has been archived on 2024-04-30. You can view files and clone it, but cannot push or open issues or pull requests.
setup/roles/neovim/tasks/main.yml

34 lines
983 B
YAML

- name: Download Neovim PPA signing key
become: true
apt_key:
keyserver: keyserver.ubuntu.com
id: 9DBB0BE9366964F134855E2255F96FCF8231B6DD
keyring: /etc/apt/keyrings/neovim.gpg
- name: Install Neovim PPA
become: true
apt_repository:
repo: "deb [signed-by=/etc/apt/keyrings/neovim.gpg] https://ppa.launchpadcontent.net/neovim-ppa/stable/ubuntu {{ ansible_distribution_release }} main"
register: apt_repository
- name: Update APT cache
become: true
apt:
update_cache: true
when: apt_repository.changed
- name: Install Neovim
become: true
apt:
name: neovim
- name: Create pack directory
file:
path: ~/.config/nvim/pack/packer/start
state: directory
recurse: true
- name: Clone packer repository
git:
repo: https://github.com/wbthomason/packer.nvim
dest: ~/.config/nvim/pack/packer/start/packer.nvim
depth: 1
- name: Copy init.lua
copy:
src: "{{ role_path }}/files/init.lua"
dest: ~/.config/nvim/init.lua