Installing neovim from binary on Ubuntu
This commit is contained in:
parent
988c38c0fd
commit
b5dfc6c811
3 changed files with 35 additions and 2 deletions
|
@ -1,5 +1,10 @@
|
||||||
if status is-interactive
|
if status is-interactive
|
||||||
fish_add_path -p $HOME/.local/bin
|
fish_add_path -p $HOME/.local/bin
|
||||||
|
|
||||||
|
if test -d /opt/nvim-linux64/bin
|
||||||
|
fish_add_path -a /opt/nvim-linux64/bin
|
||||||
|
end
|
||||||
|
|
||||||
switch (whoami)
|
switch (whoami)
|
||||||
# Corporate machine
|
# Corporate machine
|
||||||
case Ivan_Golikov
|
case Ivan_Golikov
|
||||||
|
|
|
@ -2,7 +2,6 @@
|
||||||
- hosts: all
|
- hosts: all
|
||||||
vars:
|
vars:
|
||||||
common_packages:
|
common_packages:
|
||||||
- neovim
|
|
||||||
- ripgrep
|
- ripgrep
|
||||||
- tree
|
- tree
|
||||||
- gcc
|
- gcc
|
||||||
|
@ -13,10 +12,12 @@
|
||||||
- fzf
|
- fzf
|
||||||
|
|
||||||
brew_packages:
|
brew_packages:
|
||||||
|
- neovim
|
||||||
- difftastic
|
- difftastic
|
||||||
- fd
|
- fd
|
||||||
|
|
||||||
pacman_packages:
|
pacman_packages:
|
||||||
|
- neovim
|
||||||
- difftastic
|
- difftastic
|
||||||
- fd
|
- fd
|
||||||
|
|
||||||
|
@ -78,6 +79,33 @@
|
||||||
pkg: "{{ common_packages }}"
|
pkg: "{{ common_packages }}"
|
||||||
cache_valid_time: 3600
|
cache_valid_time: 3600
|
||||||
|
|
||||||
|
- name: Install Neovim (Ubuntu)
|
||||||
|
when: is_ubuntu
|
||||||
|
block:
|
||||||
|
- name: Create a temporary directory
|
||||||
|
ansible.builtin.tempfile:
|
||||||
|
state: directory
|
||||||
|
prefix: uv_temp_
|
||||||
|
register: temp_dir
|
||||||
|
|
||||||
|
- name: Download Neovim tarball
|
||||||
|
ansible.builtin.get_url:
|
||||||
|
url: 'https://github.com/neovim/neovim/releases/latest/download/nvim-linux64.tar.gz'
|
||||||
|
dest: "{{ temp_dir.path }}/nvim.tar.gz"
|
||||||
|
mode: 'u=r,g=,o='
|
||||||
|
|
||||||
|
- name: Unpack the tarball
|
||||||
|
become: true
|
||||||
|
ansible.builtin.unarchive:
|
||||||
|
src: "{{ temp_dir.path }}/nvim.tar.gz"
|
||||||
|
dest: "/opt"
|
||||||
|
remote_src: true
|
||||||
|
|
||||||
|
- name: Clean up temporary directory
|
||||||
|
ansible.builtin.file:
|
||||||
|
path: "{{ temp_dir.path }}"
|
||||||
|
state: absent
|
||||||
|
|
||||||
- name: Install uv packages
|
- name: Install uv packages
|
||||||
ansible.builtin.command: "uv tool install --python {{ item.python | default(uv_tools_default_python) }} {{ item.name }}"
|
ansible.builtin.command: "uv tool install --python {{ item.python | default(uv_tools_default_python) }} {{ item.name }}"
|
||||||
register: uv_install_result
|
register: uv_install_result
|
|
@ -10,7 +10,7 @@ $ alias dotfiles='/usr/bin/git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME'
|
||||||
$ dotfiles checkout
|
$ dotfiles checkout
|
||||||
$ dotfiles config --local status.showUntrackedFiles no
|
$ dotfiles config --local status.showUntrackedFiles no
|
||||||
$ cd .local/share/dotfiles
|
$ cd .local/share/dotfiles
|
||||||
$ uv run ansible-playbook install_dev_tools.yml
|
$ uv run ansible-playbook install_dotfiles.yml
|
||||||
```
|
```
|
||||||
|
|
||||||
## TODO
|
## TODO
|
||||||
|
|
Loading…
Reference in a new issue