Store pynvim setup in dedicated virtualenv, make using Makefile
This commit is contained in:
parent
b3a5fa3202
commit
4361a7812a
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -11,3 +11,4 @@ config/fish/fish_variables
|
||||||
config/gtk-3.0/bookmarks
|
config/gtk-3.0/bookmarks
|
||||||
config/xfce4/xfconf/xfce-perchannel-xml
|
config/xfce4/xfconf/xfce-perchannel-xml
|
||||||
config/i3/config.d
|
config/i3/config.d
|
||||||
|
config/nvim/.venv
|
||||||
|
|
9
Makefile
9
Makefile
|
@ -32,12 +32,13 @@ unlink:
|
||||||
for link in $(THEMES_TARGETS); do rm "$$link"; done
|
for link in $(THEMES_TARGETS); do rm "$$link"; done
|
||||||
rmdir $(HOME)/.ssh/sockets
|
rmdir $(HOME)/.ssh/sockets
|
||||||
|
|
||||||
install: $(LAZY_DIR) $(PYENV_DIR) $(POETRY_DIR)
|
install: $(LAZY_DIR) $(PYENV_DIR) $(POETRY_DIR) config/nvim/.venv
|
||||||
|
|
||||||
uninstall:
|
uninstall:
|
||||||
rm -rf $(LAZY_DIR)
|
rm -rf $(LAZY_DIR)
|
||||||
rm -rf $(PYENV_DIR)
|
rm -rf $(PYENV_DIR)
|
||||||
rm -rf $(POETRY_DIR)
|
rm -rf $(POETRY_DIR)
|
||||||
|
rm -rf config/nvim/.venv
|
||||||
|
|
||||||
$(CONFIG_TARGETS): $(CONFIG_DIR)/%: config/%
|
$(CONFIG_TARGETS): $(CONFIG_DIR)/%: config/%
|
||||||
$(SSH_TARGETS): $(SSH_DIR)/%: ssh/%
|
$(SSH_TARGETS): $(SSH_DIR)/%: ssh/%
|
||||||
|
@ -55,5 +56,11 @@ $(PYENV_DIR):
|
||||||
$(POETRY_DIR):
|
$(POETRY_DIR):
|
||||||
python3 packages/poetry.py
|
python3 packages/poetry.py
|
||||||
|
|
||||||
|
config/nvim/.venv:
|
||||||
|
python3 -m venv $@
|
||||||
|
$@/bin/python3 -m pip install -U pip wheel
|
||||||
|
$@/bin/python3 -m pip install --use-pep517 pynvim
|
||||||
|
|
||||||
|
|
||||||
$(CONFIG_DIR) $(SSH_DIR) $(THEMES_DIR) $(HOME)/.ssh/sockets:
|
$(CONFIG_DIR) $(SSH_DIR) $(THEMES_DIR) $(HOME)/.ssh/sockets:
|
||||||
mkdir -p $@
|
mkdir -p $@
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
if status is-interactive
|
if status is-interactive
|
||||||
set -gx PYENV_ROOT $HOME/.pyenv
|
set -gx PYENV_ROOT $HOME/.pyenv
|
||||||
set -g fish_user_paths $PYENV_ROOT/bin $fish_user_paths
|
set -g fish_user_paths $PYENV_ROOT/bin $fish_user_paths
|
||||||
pyenv init - | source
|
|
||||||
end
|
end
|
||||||
|
|
1
config/nvim/.envrc
Normal file
1
config/nvim/.envrc
Normal file
|
@ -0,0 +1 @@
|
||||||
|
source .venv/bin/activate
|
|
@ -1,6 +1,6 @@
|
||||||
vim.opt.title = true
|
vim.opt.title = true
|
||||||
vim.opt.cmdheight = 0
|
vim.opt.cmdheight = 0
|
||||||
vim.g.python3_host_prog = "/usr/bin/python3"
|
vim.g.python3_host_prog = vim.fn.stdpath "config" .. "/.venv/bin/python"
|
||||||
vim.g.python_indent = {
|
vim.g.python_indent = {
|
||||||
open_paren = "shiftwidth()",
|
open_paren = "shiftwidth()",
|
||||||
nested_paren = "shiftwidth()",
|
nested_paren = "shiftwidth()",
|
||||||
|
|
Loading…
Reference in a new issue