Notices


Reply
Thread Tools
Posts: 527 | Thanked: 121 times | Joined on Feb 2010
#281
I had these issues as well but these were mainly due to trying to ad sudo gainroot to the script...

Example:

I want homunculus to start from root...
I couldn't make a script that worked so all hell broke loose and I got errors about hildon-desktop closing down
 

The Following User Says Thank You to rolan900d For This Useful Post:
Posts: 284 | Thanked: 75 times | Joined on Nov 2009
#282
Ahh, this actually ties in with something I was doing.

The first time I installed it was working perfectly, until I tried to start cuteexplorer as root... Think I used:

sudo gainroot; cuteexplorer - had no idea if that was right but it didn't like it! I've since uninstalled and reinstalled and now I can't get it to load up even once which is a shame. Any solution?
 
Posts: 156 | Thanked: 90 times | Joined on Jan 2010
#283
 

The Following User Says Thank You to rooted For This Useful Post:
Posts: 284 | Thanked: 75 times | Joined on Nov 2009
#284
Originally Posted by rooted View Post
To both of you:

echo "command" | sudo gainroot
Ahh I wish I'd known that before I killed the app...!! It doesn't let me do anything with it if I reinstall now...This is why linux n00bs shouldn't play with these things. *points finger at himself*

Any idea what the app could have done to hildon-desktop though? Seemingly everytime I reinstall it, something has been leftover from the previous install...

I will be flashing when/if 1.2 comes out but would prefer to not before that.
 
Posts: 47 | Thanked: 22 times | Joined on Apr 2010
#286
Here's a little python script I use to get the verse of the day from BibleGateway

Code:
import feedparser
try:
	feed_in = feedparser.parse('http://www.biblegateway.com/votd/get/?format=atom')
	try:
		feed = str(feed_in.entries[0].title)
		print feed
	except:
		print 'No Content'
except:
	print 'Not Connected'
You need the feedparser module which can be gotten from Here
 
Posts: 169 | Thanked: 41 times | Joined on Apr 2010 @ Portugal
#287
Hi all,
Please i'll apreciate a little help with QBW scripting.

Yes, i know if i do echo "command" | sudo gainroot, it will work.
But..and if it is not a "command" ?

Just like this..I want to make 2 profiles with my personalized OC settings (day\night profile). I'll put here the code for one of them:

/usr/sbin/kernel-load /usr/share/kernel-power-settings/ideal
rm -f /etc/default/kernel-power
ln -s /usr/share/kernel-power-settings/ideal /etc/default/kernel-power
echo 125000 250000 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/avoid_frequencies
echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/ignore_nice_load
/usr/sbin/kernel-load

How can i make it run with QBW?
If i run it at Xterm, with root, it works.
If i try it with QBW, it doesent work.

I've tried this too, but..nothing..

/usr/sbin/kernel-load /usr/share/kernel-power-settings/ideal
rm -f /etc/default/kernel-power | sudo gainroot
ln -s /usr/share/kernel-power-settings/ideal /etc/default/kernel-power | sudo gainroot
echo "echo 125000 250000 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/avoid_frequencies" | sudo gainroot
echo "echo 0 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/ignore_nice_load" | sudo gainroot
/usr/sbin/kernel-load |sudo gainroot

Can please anyone help me? it works like i want on Xterminal.but cant 'export' it to Queen Beecon Widget..help please... (actualy, it acept the code, with no errors but it doesent change any values.

Last edited by nokian-series; 2010-04-25 at 01:35. Reason: Correct missing 'code'.
 
No!No!No!Yes!'s Avatar
Posts: 700 | Thanked: 846 times | Joined on Nov 2009
#288
Originally Posted by nokian-series View Post
Hi all,
Please i'll apreciate a little help with QBW scripting.

Yes, i know if i do echo "command" | sudo gainroot, it will work.
But..and if it is not a "command" ?

Just like this..I want to make 2 profiles with my personalized OC settings (day\night profile). I'll put here the code for one of them:

/usr/sbin/kernel-load /usr/share/kernel-power-settings/ideal
rm -f /etc/default/kernel-power
ln -s /usr/share/kernel-power-settings/ideal /etc/default/kernel-power
echo 125000 250000 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/avoid_frequencies
echo 0 > /sys/devices/system/cpu/cpufreq/ondemand/ignore_nice_load
/usr/sbin/kernel-load

How can i make it run with QBW?
If i run it at Xterm, with root, it works.
If i try it with QBW, it doesent work.

I've tried this too, but..nothing..

/usr/sbin/kernel-load /usr/share/kernel-power-settings/ideal
rm -f /etc/default/kernel-power | sudo gainroot
ln -s /usr/share/kernel-power-settings/ideal /etc/default/kernel-power | sudo gainroot
echo "echo 125000 250000 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/avoid_frequencies" | sudo gainroot
echo "echo 0 > /sys/devices/system/cpu/cpufreq/ondemand/ignore_nice_load" | sudo gainroot
/usr/sbin/kernel-load |sudo gainroot

Can please anyone help me? it works like i want on Xterminal.but cant 'export' it to Queen Beecon Widget..help please... (actualy, it acept the code, with no errors but it doesent change any values.
You cannot paste it directly into QBW.
You need to connect to X-Terminal for that and then...:
Code:
 ~ $
cd /home/user
cat > myscript.sh
<here you paste the script>
#!/bin/sh
/usr/sbin/kernel-load /usr/share/kernel-power-settings/ideal
rm -f /etc/default/kernel-power
ln -s /usr/share/kernel-power-settings/ideal /etc/default/kernel-power
echo 125000 250000 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/avoid_frequencies
echo 0 > /sys/devices/system/cpu/cpufreq/ondemand/ignore_nice_load
/usr/sbin/kernel-load

<then you press CTRL-D and you get the prompt again>

~ $ chmod 755 myscript.sh
Now you can "AddCmd": echo "/home/user/myscript.sh" | sudo gainroot

... and see what happens.
__________________
Have a look at Queen BeeCon Widget (WIKI) Customizable and flexible widget-based multi-instance monitoring, alerting and interactive tool for the N900
Please provide comments and feedback for having QBW supported and enhanced further - (DONATE) - v1.3.3devel / v1.3.3testing / v1.3.3extras
 

The Following User Says Thank You to No!No!No!Yes! For This Useful Post:
Posts: 169 | Thanked: 41 times | Joined on Apr 2010 @ Portugal
#289
It dont have the result i've expected.
(if i do it from xterminal, line by line, it works ... )


Originally Posted by No!No!No!Yes! View Post
You cannot paste it directly into QBW.
You need to connect to X-Terminal for that and then...:
Code:
 ~ $
cd /home/user
cat > myscript.sh
<here you paste the script>
#!/bin/sh
/usr/sbin/kernel-load /usr/share/kernel-power-settings/ideal
rm -f /etc/default/kernel-power
ln -s /usr/share/kernel-power-settings/ideal /etc/default/kernel-power
echo 125000 250000 > /sys/devices/system/cpu/cpu0/cpufreq/ondemand/avoid_frequencies
echo 0 > /sys/devices/system/cpu/cpufreq/ondemand/ignore_nice_load
/usr/sbin/kernel-load

<then you press CTRL-D and you get the prompt again>

~ $ chmod 755 myscript.sh
Now you can "AddCmd": echo "/home/user/myscript.sh" | sudo gainroot

... and see what happens.
 
Posts: 169 | Thanked: 41 times | Joined on Apr 2010 @ Portugal
#290
Is there another way to execute that commands with 'root' ?! Or i'm doing anything wrong with that method of script.sh ?
 
Reply


 
Forum Jump


All times are GMT. The time now is 15:41.