Install pyenv and poetry using own installers

This commit is contained in:
Evie Litherland-Smith 2023-02-27 10:39:04 +00:00
parent 023c42598e
commit a1d5a99d10
4 changed files with 21 additions and 5 deletions

View file

@ -9,6 +9,12 @@ SSH_TARGETS := $(SSH_ITEMS:ssh/%=$(SSH_DIR)/%)
LAZY_REPO := https://github.com/folke/lazy.nvim.git
LAZY_DIR := $(HOME)/.local/share/nvim/lazy/lazy.nvim
PYENV_INSTALLER := https://pyenv.run
PYENV_DIR := $(if $(PYENV_ROOT), $(PYENV_ROOT), $(HOME)/.pyenv)
POETRY_INSTALLER := https://install.python-poetry.org
POETRY_DIR := $(HOME)/.local/share/pypoetry
.PHONY: all clean link unlink install uninstall pacman
all: link install
@ -23,7 +29,7 @@ unlink:
rmdir $(HOME)/.local/share/fonts
rmdir $(HOME)/.ssh/sockets
install: $(LAZY_DIR)
install: $(LAZY_DIR) $(PYENV_DIR) $(POETRY_DIR)
uninstall:
rm -rf $(LAZY_DIR)
@ -39,5 +45,11 @@ $(HOME)/.local/share/fonts: fonts
$(LAZY_DIR):
git clone --depth 1 $(LAZY_REPO) $@
$(PYENV_DIR):
curl $(PYENV_INSTALLER) | bash
$(POETRY_DIR):
curl -sSL $(POETRY_INSTALLER) | python3 -
$(CONFIG_DIR) $(SSH_DIR) $(HOME)/.ssh/sockets:
mkdir -p $@

View file

@ -1,6 +1,6 @@
if status is-interactive
set -l LOCAL_BIN "$HOME/.local/bin"
set -l DOTFILES_BIN "$HOME/.dotfiles/bin"
echo $PATH | grep -i $LOCAL_BIN - > /dev/null 2>&1 || set -gx PATH $PATH $LOCAL_BIN
echo $PATH | grep -i $DOTFILES_BIN - > /dev/null 2>&1 || set -gx PATH $PATH $DOTFILES_BIN
echo $fish_user_paths | grep -i $LOCAL_BIN - > /dev/null 2>&1 || set -g fish_user_paths $fish_user_paths $LOCAL_BIN
echo $fish_user_paths | grep -i $DOTFILES_BIN - > /dev/null 2>&1 || set -g fish_user_paths $fish_user_paths $DOTFILES_BIN
end

View file

@ -1,4 +1,5 @@
if status is-interactive
set -gx PYENV_ROOT $HOME/.pyenv
set -g fish_user_paths $PYENV_ROOT/bin $fish_user_paths
pyenv init - | source
end

View file

@ -1,6 +1,9 @@
pyenv
python
python-pip
python-poetry
python-pynvim
python-virtualenv
base-devel
openssl
zlib
xz
tk