bb9d34c33f
Some echo message contain error or warning message which better be contain in stderr. And futher more some error message already contain in stderr, but for error message reader, the following information for that echo should be contained as well. Change-Id: I2aac631df19829218d446150c91cf6d50aa5e7e7
22 lines
489 B
Bash
Executable File
22 lines
489 B
Bash
Executable File
#!/bin/bash
|
|
|
|
if [ $EUID -ne 0 ]; then
|
|
echo "This script must be run as root." >&2
|
|
exit
|
|
fi
|
|
|
|
type -P pip-python &> /dev/null && have_pip_python=1 || have_pip_python=0
|
|
if [ $have_pip_python -eq 1 ]; then
|
|
pip-python uninstall -y heat
|
|
exit
|
|
fi
|
|
|
|
type -P pip &> /dev/null && have_pip=1 || have_pip=0
|
|
if [ $have_pip -eq 1 ]; then
|
|
pip uninstall -y heat
|
|
exit
|
|
fi
|
|
|
|
echo "pip-python not found. install package (probably python-pip) or run
|
|
'easy_install pip', then rerun $0" >&2;
|