Closed nixjdm closed 4 years ago
and 3 ought to be the default.
@nixjdm This is done, those seem like bs fixes, but i've tested both and comply with the minimum requirements. Please make clear if python2 compatibility is required or if a selection should be offered. Otherwise it is ready.
I think we should support Python 2 only as long as we officially support Python 2. I guess that means one more release?
Ok I'll figure a way to test for both and pass the script to the right one. Another question @runfalk : in case both are installed (weird but possible) which should be prioritized? I'm guessing python3 should, right?
I think having both is really common, at least it was very common in Linux distros until recently.
I think prioritizing Python 3 makes most sense since Python 2 is dying. I guess the check could be something like:
if hash python3 2> /dev/null; then
PYTHON_BIN="python3"
elif hash python 2> /dev/null; then
PYTHON_BIN="python"
else
echo "Error: To use this script you need to have Python installed"
exit 1
fi
$PYTHON_BIN - <<'EOF'
I'll test and add to PR.
Closed in 1a059fa... sort of. The installer is now python, and works with 2 and 3. Hopefully the user decides to use 3, as suggested by the docs.
It was reported that some distros are no longer shipping with Python 3 ,and also we apparently were relying on Python 2 in our install scripts. We ought to handle both!