Latest LQ Deal: Linux Power User Bundle
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 12-11-2010, 05:56 AM   #1
Registered: Dec 2009
Distribution: Arch
Posts: 103

Rep: Reputation: 2
Question making a ('list'?) of commands to run

i have a java program and to run it, i have to go into terminal and type
cd <where the file is>
java -jar <filename>.jar
this works fine, but is there a way to make a shortcut/small program to do this for me when i double click?
Old 12-11-2010, 06:32 AM   #2
Senior Member
Registered: Dec 2005
Location: Massachusetts, USA
Distribution: Ubuntu 10.04 and CentOS 5.5
Posts: 3,873

Rep: Reputation: 333Reputation: 333Reputation: 333Reputation: 333
You appear to be using Ubuntu. If that is correct then you can move the mouse pointer to an empty area on the desktop and click the right mouse button. A menu will appear. Click on "Create Launcher...". A window will appear with a form to fill in. When you have finished entering the appropriate information then click on the "OK" button in the lower right of the window. When you do this an icon will appear on your desktop.
Old 12-11-2010, 06:37 AM   #3
Registered: Dec 2009
Distribution: Arch
Posts: 103

Original Poster
Rep: Reputation: 2
thanks, i really wasnt sure what to do

Old 12-11-2010, 09:20 AM   #4
LQ 5k Club
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2017 CentOS6.9 CentOS7.4 + 50+ other Linux OS, for test only.
Posts: 17,040

Rep: Reputation: 3456Reputation: 3456Reputation: 3456Reputation: 3456Reputation: 3456Reputation: 3456Reputation: 3456Reputation: 3456Reputation: 3456Reputation: 3456Reputation: 3456
A launcher may not always work.

But a script can. Make it executable, and cp script /usr/local/bin/
cd <where the file is>
java -jar <filename>.jar
A launcher can then start the <script>.


command, java, list, string, terminal

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
list of commands eric2000 Linux - Newbie 6 01-06-2006 02:17 AM
Making some commands run everytime I start Linux (Slack 9.1) Agna Linux - Newbie 7 08-26-2005 09:38 PM
Script to Run the Same Commands on a List of Files Chryzmo Programming 1 10-03-2004 08:34 AM
Making Commands for an Applikation dragomir Linux - Newbie 2 02-21-2004 08:23 PM
list of commands JROCK1980 Linux - General 2 02-16-2004 06:07 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 12:58 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration