Reply
Thread Tools
Posts: 5 | Thanked: 0 times | Joined on Jan 2013 @ UK; http://stackoverflow.com/users/737641/a12jun
#11
Hi,

I got the app working from the homescreen as a simple one-way set. But as pointed out I want to make it a toggling app so that it switches between two settings.

I have created the following script file:

Code:
 #!/bin/sh
if [gconftool-2 --get /system/oss/dsm/display/color_profile == Muted];
then
gconftool-2 --set --type=string /system/osso/dsm/display/color_profile Vivid;
gconftool-2 --set --type=string /system/osso/dsm/display/display_brightness 5;
else
gconftool-2 --set --type=string /system/osso/dsm/display/color_profile Muted;
gconftool-2 --set --type=string /system/osso/dsm/display/display_brightness 1;
fi
But I get the error
Code:
./toggle_colour_profile.sh: line 9: [gconftool-2: not found
I have tried with/without the semi colons and also with { } around the set statements. Is there something else I am doing wrong?
 
Posts: 299 | Thanked: 557 times | Joined on Aug 2012
#12
Code:
if [gconftool-2 --get /system/oss/dsm/display/color_profile == Muted];
That's the first typo.

Should look more like this:
Code:
if [ `gconftool-2 --get /system/osso/dsm/display/color_profile` == "Muted" ];

Last edited by brkn; 2013-01-12 at 12:00.
 

The Following User Says Thank You to brkn For This Useful Post:
Reply

Tags
fail university, rofl_


 
Forum Jump


All times are GMT. The time now is 17:27.