app-eselect/eselect-python: Do not update meaningless py2 preference
authorMichał Górny <mgorny@gentoo.org>
Sat, 6 Feb 2016 09:33:11 +0000 (10:33 +0100)
committerMichał Górny <mgorny@gentoo.org>
Sat, 6 Feb 2016 09:57:35 +0000 (10:57 +0100)
We no longer support more than one version of Python 2, so the Python2
preference is no longer meaningful and causes Python 2 to be preferred
over non-preferred versions of Python 3.

app-eselect/eselect-python/eselect-python-99999999.ebuild

index f9b8c65f2602e678f146576f64abaea55b37a585..52eb0ceceb522c1561f265fb0ac7b46ab1a75974 100644 (file)
@@ -33,9 +33,7 @@ pkg_postinst() {
                eselect python update --if-unset
        fi
 
-       for py in 2 3; do
-               if has_version "=dev-lang/python-${py}*"; then
-                       eselect python update "--python${py}" --if-unset
-               fi
-       done
+       if has_version "=dev-lang/python-3*"; then
+               eselect python update "--python3" --if-unset
+       fi
 }