Bash Script for Banshee Development

Because Banshee doesn’t have a “make run” target in the automake, you have to install Banshee each and every compile to test revisions. I also need to do things like delete the user database and run the program after its built and installed. To do this I’ve written a little Bash script to shortcut some of the typing that I was doing.

Here it is for anyone else who may want to use it:

#!/bin/bash

MESSAGE="\033[1;32m=!=\e[0m"

if [ "$1" = "c" ]; then
echo -e "${MESSAGE} Cleaning..."
make clean
rm $HOME/.gnome2/banshee/banshee.db
fi

if [ "$1" = "s" ]; then
echo -e "${MESSAGE} Saving database..."
else
echo -e "${MESSAGE} Removing database..."
rm $HOME/.gnome2/banshee/banshee.db
fi

make
if [ "$?" -ne "0" ]; then
echo -e "${MESSAGE} Make failed..."
exit 1
fi

make install
if [ "$?" -ne "0" ]; then
echo -e "${MESSAGE} Install failed..."
exit 1
fi

echo -e "${MESSAGE} Install SUCCESSFUL!"
echo -e "${MESSAGE} Run?"

read RUN

if [ "$RUN" != "n" ]; then
mono --debug ../root/lib/banshee/banshee.exe
fi

exit 0

    None Found
  • http://abock.org Aaron Bockover

    Luke: you can now use “make run” from src/ to run Banshee uninstalled.

  • http://www.openradix.org/ Luke Hoersten

    Excellent. Thanks Aaron.

  • http://abock.org Aaron Bockover

    Luke: you can now use “make run” from src/ to run Banshee uninstalled.

  • http://www.openradix.org/ Luke Hoersten

    Excellent. Thanks Aaron.