#!/bin/bash

VERSION=`python --version | awk '{split($2,a,"."); printf "%s.%s", a[1], a[2]}'`
PIPLOC=`which python | sed 's/bin\/python//g'`
PIPLOC=$PIPLOC/lib/python$VERSION/site-packages
echo $PIPLOC

echo 'Try installing $1 to $PIPLOC'
pip --exists-action i install --target $PIPLOC $1
