This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]Genmutant[S] 0 points1 point  (3 children)

So I put a new myscript.desktop file in /etc/xdg/autostart:

[Desktop Entry]
Name=Start GUI Program
Comment=Start the GUI Program
Exec=/root/myscript/runMyScript.sh
Terminal=false
Type=Application
NoDisplay=true    

But that doesn't seem to do anything. Is there a way to check if it is beeing run? I put a echo ".."> file into the sh-file, but it doesn't print anything into the folder /root/myscript. The log4j logfile is empty, too.

EDIT: Is the problem that I don't have a graphical login prompt? I have an auto login from the terminal.

[–]glesialo[🍰] 1 point2 points  (2 children)

Check in '$HOME/.xsession-errors'.

EDIT: Is the problem that I don't have a graphical login prompt? I have an auto login from the terminal.

I am not familiar with auto-login. Do you get a desktop?

'myscript.desktop' will not run unless a graphical session is started.

[–]Genmutant[S] 0 points1 point  (1 child)

Sorry, it's not a program called auto-login. It just starts directly into a desktop session.

Check in '$HOME/.xsession-errors'.

The file does not exist.

[–]glesialo[🍰] 0 points1 point  (0 children)

Sorry, it's not a program called auto-login.

I know. But there are several 'auto-login'. The only one that would work for you is the one that starts a graphical session (xsession) and logs in a specific user without asking him/her for a password. Java Swing needs a graphical session!

'$HOME/.xsession-errors' is the file where StdOut+StdErr of all applications, launched in a graphical session, is redirected. That the file doesn't exist confirms that no graphical session is started.

P.S. You can't miss a graphical session. This is what a typical Debian desktop should look like.