Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Re: Starting java appications
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Starting java appications



on 8/31/01 4:41 PM, Nick Kledzik at email@hidden wrote:

> If you make a shell script file that ends in .command and has the x bit
> set, you can double click it from the Finder which wil launch
> Terminal.app and run the script.

Except that when you do it this way the script is run from your home
directory. So if your script isn't in your home directory and wants to
access files in its directory using a relative path, it won't work right.
(You'd have to use an absolute path.)

This is how it worked last time I checked, but that was a long time ago.

It'd be so much easier if I could just make a script with this:

java -jar app.jar

Name it "app.command", set it's x bit, and then be able to double click on
it to launch an app.

Instead I have to use the Jar's absolute path which means I can't move the
.command file around (without changing it) when I move the Jar.

I wish it worked differently, but oh well...
____________________________________

Dave Thorup
Software Engineer
email@hidden
voice: 801-805-9422

www.corda.com
Interactive data driven graphics.


References: 
 >Re: Starting java appications (From: Nick Kledzik <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.