Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I have a web server .jar file (it's a jetty application) that I've created a .desktop file for. Clicking on the .desktop file opens a terminal, begins running the application, and then closes the terminal (and the application with it).

Two questions: first, how can I make this terminal persist? And secondly, the application needs to be launched from a particular directory, is there a way to specify that?

share|improve this question

1 Answer 1

You can change the Exec line of your .desktop file as

Exec=xterm -hold -e "cd <your desired directory>&&<command for your application startup here>".

This will spawn a xterm terminal emulator and hold it even after your application terminates until you explicitly close the xterm window.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.