#!/bin/sh
# A small wrapper for pychecker
# Copyright Arto Jantunen <viiru@debian.org>
# Some minor changes by Justin Hahn <jeh@profitlogic.com>

if [ ! $PYTHONVER ]; then

        # Since pychecker depends on a python install we needn't worry
        # about the case where there is no python installed unless
        # the admin has done an equivs. But we're not in the business of
        # supporting that.

        for i in /usr/bin/python \
                /usr/bin/python2.1 \
                /usr/bin/python2.2 \
                /usr/bin/python2 \
                /usr/bin/python1.5 \
                `which python`
        do
                if [ -x $i ]
                then
                        $i /usr/share/pychecker/checker.py $@
                        break
                fi
        done
else
        python$PYTHONVER /usr/share/pychecker/checker.py $@
fi