first: Base implementation, README and LICENCE
A simple tool to manage locally-installed Python versions.
You will need a Lua interpreter in your system.
The script also relies on curl
and is designed to run on POSIX systems.
Move local-python
to ~/.local/bin/local-python
if you want to.
The script relies on ~/.local/bin/
being added on your path with higher precedence than /usr/bin
.
Be sure to include a line analogous to the following in your shellrc (e.g. ~/.bashrc
):
export PATH="~/.local/bin:$PATH"
You can configure a couple of options by directly modifying the script:
Installer.BIN_PATH
: Directory in your $PATH
where a python
executable
linking to a locally installed python
executable will be found.
$HOME/.local/bin
Installer.PYTHON_PATH
: Directory where all locally installed python
executables will be installed.Run local-python
without arguments to find about each mode.
For example, you can install and set Python 3.8.16 with this call:
local-python install 3.8.16
local-python set 3.8.16
Any arguments to pass to install
after the version will be passed to make
.
For example, this will install Python 3.10.2 with 8 threads:
local-python install 3.10.2 -j8