diff --git a/.config/nvim/init.vim b/.config/nvim/init.vim index 4b61573..f590b93 100644 --- a/.config/nvim/init.vim +++ b/.config/nvim/init.vim @@ -77,7 +77,8 @@ nmap ]x ctrih/^# %% luafile $HOME/.config/nvim/plugins.lua " python stuff -let g:python3_host_prog = "$HOME/.venvs/nvim/bin/python" +" let g:python3_host_prog = "$HOME/.venvs/nvim/bin/python" +let g:python4_host_prog = "$HOME/.config/nvim/python" " VimWiki setup let g:vimwiki_sync_branch = "main" diff --git a/makefile b/makefile index d8089b0..1c789a4 100644 --- a/makefile +++ b/makefile @@ -12,7 +12,7 @@ setup_alacritty: ln -s -f ~/dotfiles/.config/alacritty/alacritty.yml ~/.config/alacritty/alacritty.yml setup_python_and_poetry: - # TODO: make raget not tested properly + # TODO: make target not tested properly # sudo apt purge python3 python3-pip python3-openssl sudo apt-get update @@ -30,9 +30,14 @@ setup_python_and_poetry: # setup poetry - zsh mkdir $ZSH_CUSTOM/plugins/poetry poetry completions zsh > $ZSH_CUSTOM/plugins/poetry/_poetry - # nvim python provider - pip3 install --upgrade pynvim - + # + # setup_nvim_python_provider + cd ~/dotfiles/nvim_python_provider && poetry install + cd ~/dotfiles/nvim_python_provider && poetry run which python > /tmp/nvim_python_provider + ln -s -f $$(cat /tmp/nvim_python_provider) ~/.config/nvim/python + rm /tmp/nvim_python_provider + ~/config/nvim/python -m pip install pynvim + # "WARNING: in nvim run :checkhealth and check python provider status" setup_tmux_a: echo "configuring tmux with 'a' as prefix" diff --git a/nvim_python_provider/poetry.lock b/nvim_python_provider/poetry.lock new file mode 100644 index 0000000..23aabce --- /dev/null +++ b/nvim_python_provider/poetry.lock @@ -0,0 +1,7 @@ +# This file is automatically @generated by Poetry 1.4.2 and should not be changed by hand. +package = [] + +[metadata] +lock-version = "2.0" +python-versions = "^3.8" +content-hash = "935b488be9f11b23f14aa1ce3bed4013d88bd77462534b5e4fe5bb82b485bfe9" diff --git a/nvim_python_provider/pyproject.toml b/nvim_python_provider/pyproject.toml new file mode 100644 index 0000000..6e424b2 --- /dev/null +++ b/nvim_python_provider/pyproject.toml @@ -0,0 +1,13 @@ +[tool.poetry] +name = "nvim-python-provider" +version = "0.1.0" +description = "poetry virtual environment for nvim" +authors = ["DannyDannyDanny "] + +[tool.poetry.dependencies] +python = "^3.8" + + +[build-system] +requires = ["poetry-core"] +build-backend = "poetry.core.masonry.api"