mirror of
https://gitlab.com/sagidayan/linux-config.git
synced 2024-11-21 23:05:25 +00:00
Neovim - treesitter only on workstation.
This commit is contained in:
parent
0a25dbdf1f
commit
f7493d2db2
4 changed files with 21 additions and 4 deletions
|
@ -1,3 +1,5 @@
|
||||||
|
local treesitter_extention_exists, _ = pcall(require, 'user.packer_extention_treesitter')
|
||||||
|
|
||||||
return require("packer").startup(function(use)
|
return require("packer").startup(function(use)
|
||||||
-- Packer can manage itself
|
-- Packer can manage itself
|
||||||
use 'wbthomason/packer.nvim'
|
use 'wbthomason/packer.nvim'
|
||||||
|
@ -60,10 +62,12 @@ return require("packer").startup(function(use)
|
||||||
requires = { { 'nvim-lua/plenary.nvim' } }
|
requires = { { 'nvim-lua/plenary.nvim' } }
|
||||||
}
|
}
|
||||||
|
|
||||||
use {
|
if treesitter_extention_exists then
|
||||||
'nvim-treesitter/nvim-treesitter',
|
use {
|
||||||
run = ':TSUpdate'
|
'nvim-treesitter/nvim-treesitter',
|
||||||
}
|
run = ':TSUpdate'
|
||||||
|
}
|
||||||
|
end
|
||||||
|
|
||||||
-- Beacon
|
-- Beacon
|
||||||
use 'danilamihailov/beacon.nvim'
|
use 'danilamihailov/beacon.nvim'
|
||||||
|
|
|
@ -5,6 +5,8 @@
|
||||||
theme: gruvbox
|
theme: gruvbox
|
||||||
# The running user
|
# The running user
|
||||||
running_user: "{{ ansible_user_id }}"
|
running_user: "{{ ansible_user_id }}"
|
||||||
|
# for nvim - workstation should install extentions
|
||||||
|
nvim_extention_treesitter: true
|
||||||
roles:
|
roles:
|
||||||
- base
|
- base
|
||||||
- fonts
|
- fonts
|
||||||
|
|
2
roles/vim_user/defaults/main.yml
Normal file
2
roles/vim_user/defaults/main.yml
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
---
|
||||||
|
nvim_extention_treesitter: false
|
|
@ -22,3 +22,12 @@
|
||||||
copy:
|
copy:
|
||||||
src: dotfiles/nvim/
|
src: dotfiles/nvim/
|
||||||
dest: ~/.config/nvim/
|
dest: ~/.config/nvim/
|
||||||
|
|
||||||
|
- name: Debug extentions
|
||||||
|
debug:
|
||||||
|
msg: "TreeSitter: {{ nvim_extention_treesitter }}"
|
||||||
|
|
||||||
|
- name: nvim extention treesitter
|
||||||
|
shell: |
|
||||||
|
echo "return {}" > ~/.config/nvim/lua/user/packer_extention_treesitter.lua
|
||||||
|
when: nvim_extention_treesitter
|
||||||
|
|
Loading…
Reference in a new issue