maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   Running mPlayer as part of boot script (https://talk.maemo.org/showthread.php?t=82405)

ug2215 2012-02-17 20:53

Running mPlayer as part of boot script
 
I'm trying to use mPlayer in a script that is started from event.d on startup. I'm under the impression that scripts from that origin are as root user and mplayer does not work as root.

I've tried su user -c "mplayer <file>" but that didn't work.

Anyone know how to do this?

timoph 2012-02-17 22:10

Re: Running mPlayer as part of boot script
 
upstart script feels a bit wrong place to do it for me. You could write a desktop file that has the mplayer launch command in the exec line and put the created desktop file in /etc/xdg/autostart/

You can take an existing one from /usr/share/applications/hildon/ and modify it. info about desktop files: http://wiki.maemo.org/Desktop_file_format

ug2215 2012-02-18 19:34

Re: Running mPlayer as part of boot script
 
Hey, very cool. Thanks for showing me these options, I had made a couple shortcuts before but these are great.

ug2215 2012-02-20 20:15

Re: Running mPlayer as part of boot script
 
I still haven't been able to get a program to start on boot this way.

My .desktop file reads
Code:

[Desktop Entry]
Encoding=UTF-8
Name=MyProgram
Comment=Do Stuff
Icon=
Exec=PATHTOPROGRAM
Type=Application
Version=1.0
X-Maemo-Prestarted=always
NoDisplay=true

I tried to copy from the existing trackerd file in the directory but didn't make any progress. This is trimmed down a bit from what I tried first, no success from any version though.


All times are GMT. The time now is 06:53.

vBulletin® Version 3.8.8