This week's book giveaway is in the Agile and other Processes forum. We're giving away four copies of The Mikado Method and have Ola Ellnestam and Daniel Brolund on-line! See this thread for details.
What is the secret to running an executable jar file on Linux by clicking on the file? I have java 1.5.x that came with the distro, but is from Sun, is there a missing file?
I can run it via command line.
Ernest Friedman-Hill
author and iconoclast
Marshal
Depends on the Linux desktop you're using. It's just a matter of adding a file association so that ${JAVA_HOME}/bin/java is used to launch jar files with the proper command-line arguments -- but the details of doing so are distro- and/or desktop- specific.
Originally posted by Guy Allard: Linux (and any Unix) does not have the concept of "file extension associations" in the way Windows does.
Ummmmm... Guy, wake up -- it's 2007!
All the popular Linux desktops (KDE, Gnome, etc) offer this feature, and have for some years now. Most distros include a large number of such associations out of the box, including clickable jar files.
<nitpick-mode> Technically, he's right. Linux doesn't. </nitpick-mode>
But then again, the desktop GUI shell (a/k/a the "desktop") is neither part of Linux, nor its most popular GUI add-on (X Windows). Gnome, KDE, sawfish, etc. are GUI layers independent of the OS or window managers.
But, as Ernest has pointed out, these days most of them do support some sort of mapping between desktop objects and applications.
Customer surveys are for companies who didn't pay proper attention to begin with.
Originally posted by Tim Holloway: <nitpick-mode> Technically, he's right. Linux doesn't. </nitpick-mode>
<nitpick-mode> Technically, Windows can only execute .exe, .bat and .com -Files, and uses a similar technique, to associate Files to Programs. </nitpick-mode>
Originally posted by Tim Holloway: <nitpick-mode> Technically, he's right. Linux doesn't. </nitpick-mode>
Indeed; and to the same extent, it doesn't have the notion of "clicking on files!" To the extent that "clicking on files" has some reality, then file associations do, too
Guy Allard
Ranch Hand
Joined: Nov 24, 2000
Posts: 776
posted
0
Yes, but the notion of a file being executable is embedded in the OS.
And the various GUI implementations support that. Naturally.