alexbt / stock-portfolio-manager

Automatically exported from code.google.com/p/stock-portfolio-manager
0 stars 0 forks source link

launching from linux is not as easy as it could be #43

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. extract the software
2. double-click on StockPortfolioLauncher.jar
3. Get an error dialog:

"The file '/home/olivier/soft/StockPortfolio/StockPortfolioLauncher.jar' is not 
marked as executable.  If this was downloaded or copied from an untrusted 
source, it may be dangerous to run.  For more details, read about the 
executable bit."

What is the expected output? What do you see instead?

It would run the program.

What version of the product are you using? On what operating system?

0.15beta, ubuntu linux

Please provide any additional information below.

Marking the .jar as executable in the zip file would most likely fix it. 
Otherwise providing a simple launch.sh could do it and might even be simpler 
for the end user (and cross-platform with the Mac). That said, the Launcher 
name makes it pretty clear it's the jar you need to run.

Let me know if you want to go the launch.sh way, I can quickly code one for you.

Original issue reported on code.google.com by olivier....@gmail.com on 21 Jul 2011 at 1:55

GoogleCodeExporter commented 9 years ago
Workaround: mark the launcher as executable then run

Original comment by olivier....@gmail.com on 21 Jul 2011 at 3:28

GoogleCodeExporter commented 9 years ago

Original comment by alex.bel...@gmail.com on 22 Jul 2011 at 4:03

GoogleCodeExporter commented 9 years ago
I searched a bit for the best way(tm) to do this cross-platform and I couldn't 
find anything better than people suggesting a wrapper shell script.

Assuming one has already java installed and in its $PATH, a shell script can be 
as simple as the one attached.

However, with the shell script you have the exact same problem as before: if 
distributed in a zip file it will not be executable (zip doesn't store file 
permissions). Clicking on a non-executable shell script from linux opens it as 
a text file which is not what you want.

Could you generate tarballs (.tar.gz) in your build/release process? You could 
release both .zip and .tar.gz versions simultaneously. .tar.gz have permission 
information embedded so you mark both the main .jar and the attached launch.sh 
as executable and you have it pretty much covered.

Original comment by olivier....@gmail.com on 6 Sep 2011 at 3:33

Attachments:

GoogleCodeExporter commented 9 years ago
Added an even better unix launcher to issue #44.

Original comment by olivier....@gmail.com on 6 Sep 2011 at 4:40

GoogleCodeExporter commented 9 years ago

Original comment by alex.bel...@gmail.com on 9 Sep 2011 at 9:08

GoogleCodeExporter commented 9 years ago

Original comment by alex.bel...@gmail.com on 9 Sep 2011 at 9:09