Browse Source

Eselect Python automatically only if PYTHON_ESELECT=TRUE set.

master
Kolan Sh 5 years ago
parent
commit
99cd731498
2 changed files with 6 additions and 2 deletions
  1. +1
    -0
      etc/gentoo-upgrade.conf
  2. +5
    -2
      sbin/gentoo-upgrade.sh

+ 1
- 0
etc/gentoo-upgrade.conf View File

@ -1,4 +1,5 @@
EGENCACHE=FALSE
ECLEAN_DISTFILES=TRUE
PYTHON_ESELECT=FALSE
RW_REMOUNT='/boot'
RO_REMOUNT='/boot'

+ 5
- 2
sbin/gentoo-upgrade.sh View File

@ -360,8 +360,11 @@ if [ $STAGE_CNT -eq $STAGE ]; then
echo "Running python-updater..."
touch /etc/portage/need_upgrade_python
[ 0 != $? ] && echo "Stage $STAGE: cann't touch /etc/portage/need_upgrade_python ;-( =======" && exit $STAGE
eselect python set $new_python
[ 0 != $? ] && echo "Stage $STAGE: cann't switch to another python version ;-( =======" && exit $STAGE
in_list "$PYTHON_ESELECT" ${TRUE_LIST[@]}
if [ 0 -eq $? ]; then
eselect python set $new_python
[ 0 != $? ] && echo "Stage $STAGE: cann't switch to another python version ;-( =======" && exit $STAGE
fi
if [ `which python-updater 2>/dev/null` ]; then
$NICE_CMD python-updater


Loading…
Cancel
Save