allow installation with sudo privileges

This commit is contained in:
Sencer Selcuk 2014-06-20 12:43:25 -04:00 committed by Junegunn Choi
parent 84fc73ad9c
commit 7261d3afcd

View File

@ -28,7 +28,11 @@ if [ $? -eq 0 ]; then
else else
echo "Not found" echo "Not found"
echo "Installing 'curses' gem ... " echo "Installing 'curses' gem ... "
if (( EUID )); then
/usr/bin/env gem install curses -v 1.0.0 --user-install /usr/bin/env gem install curses -v 1.0.0 --user-install
else
/usr/bin/env gem install curses -v 1.0.0
fi
if [ $? -ne 0 ]; then if [ $? -ne 0 ]; then
echo echo
echo "Failed to install 'curses' gem." echo "Failed to install 'curses' gem."