Created
June 18, 2015 00:14
-
-
Save nathanchere/b16f8b5c2cf76a5cc06d to your computer and use it in GitHub Desktop.
Enabling compiz plugins from the command line
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
backupCompizConfig() { | |
gconftool-2 --get /apps/compizconfig-1/profiles/Default/general/screen0/options/active_plugins > ~/.backup/compizplugins.txt | |
} | |
addToCompizConf() { | |
TEMPVAR=$(gconftool-2 --get /apps/compizconfig-1/profiles/Default/general/screen0/options/active_plugins) | |
TEMPVAR=",${TEMPVAR:1:-1}," | |
if [ -z $(echo $TEMPVAR | grep ",$1,") ]; then | |
echo "'$1' not found; adding to Compiz conf..." | |
gconftool-2 --set --type=list --list-type=string /apps/compizconfig-1/profiles/Default/general/screen0/options/active_plugins "[${TEMPVAR:1}$1]" | |
fi | |
} | |
#Example usage | |
addToCompizConf "opengl" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment