diskimage-builder/elements/pypi/post-install.d/00-unconfigure-pypi-mirror

21 lines
302 B
Text
Raw Normal View History

#!/bin/bash
if [ ${DIB_DEBUG_TRACE:-0} -gt 0 ]; then
set -x
fi
set -eu
set -o pipefail
if [ -e ~/.pip/pip.conf.orig ]; then
mv ~/.pip/pip.conf{.orig,}
else
rm ~/.pip/pip.conf
fi
if [ -e ~/.pydistutils.cfg.orig ]; then
mv ~/.pydistutils.cfg{.orig,}
else
rm ~/.pydistutils.cfg
fi