summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAli Polatel <hawking@gentoo.org>2008-08-25 09:21:38 +0000
committerAli Polatel <hawking@gentoo.org>2008-08-25 09:21:38 +0000
commit3693bb03f07c5df701cd4f36fb7510c692c005c9 (patch)
tree4adda0fcecbe45a7007eccdb5372a0c8bfd3fcc7 /python-updater
parentMake check manual print reason without --verbose, #232467. (diff)
downloadpython-updater-3693bb03f07c5df701cd4f36fb7510c692c005c9.tar.gz
python-updater-3693bb03f07c5df701cd4f36fb7510c692c005c9.tar.bz2
python-updater-3693bb03f07c5df701cd4f36fb7510c692c005c9.zip
Tell the user to use -o switch when no previous python versions are found, #232761.
Diffstat (limited to 'python-updater')
-rwxr-xr-xpython-updater6
1 files changed, 3 insertions, 3 deletions
diff --git a/python-updater b/python-updater
index a1c3865..8942b29 100755
--- a/python-updater
+++ b/python-updater
@@ -112,14 +112,14 @@ veinfo() {
# Find old python version, return non-zero if not found
get_old_pyver() {
for old in 2.5 2.4 2.3 2.2 2.1; do
- if [[ "${old}" != "${NEW_PY_VER}" ]]; then
- if [[ -e /usr/bin/python${old} ]]; then
+ if [[ "${old}" != "${NEW_PY_VER}" && -e /usr/bin/python${old} ]]
+ then
echo -n "${old}"
return 0
- fi
fi
done
eerror "Couldn't determine any previous Python version(s)."
+ eerror "Use -o OLD_PYTHON_VERSION to specify your old python version."
return 1
}