-
Notifications
You must be signed in to change notification settings - Fork 0
/
install.sh
executable file
·32 lines (23 loc) · 913 Bytes
/
install.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/bin/bash
APPHOME=$(cd `dirname $0` && pwd)
if [ -z `which pip` ] ; then
echo "Pip (python install tool) is not installed. You can install it with apt-get install python-pip"
exit 1
fi
mkdir -p $HOME/.config
mkdir -p $HOME/.local/bin
cd $APPHOME
cp $APPHOME/default.conf $HOME/.config/cpm.conf
export PATH=$PATH:$HOME/.local/bin
echo 'export PATH=$PATH:$HOME/.local/bin' >> $HOME/.bashrc
pip install --user --editable .
if [ -z `which cpm` ] ; then
echo "Installation failed, maybe you are missing the library python-dev (needed to build python-zmq if missing)."
echo "You can install it with apt-get install python-dev"
exit 1
fi
./generate-autocomplete.sh
echo ". $APPHOME/cpm-complete.sh" >> $HOME/.bashrc
echo "Python module installation complete"
echo "2 lines have been added to your .bashrc"
echo "To complete installation, please source your .bashrc after reviewing the newly added line"