Create an empty file called "game" under /usr/bin/ , via touch command and make it executable :
$sudo touch /usr/bin/game && sudo chmod +x /usr/bin/game
Open it via gedit or your favorite editor and paste the following :
$sudo gedit /usr/bin/game
#!/bin/bash
COMP="false";
if ps -A | grep compiz > /dev/null ; then
echo "Warning: Compiz Detected!!!"
metacity --replace > /dev/null &
COMP="true"
fi
echo "Starting"
$1
echo "Finish"
if $COMP ; then
echo "Warning: Starting Compiz!!!"
compiz --replace > /dev/null &
fi
exit
Save and exit.
Now you can just type game before before your application/game command.Example :
$game eternallands
$game wesnoth
![]() | ![]() | ![]() | ![]() | ![]() |
![]() | ![]() | ![]() | ![]() | ![]() |
![]() | ![]() | ![]() | ![]() | ![]() |
![]() |
0 comments:
Post a Comment