When you launch [ganttproject "my file.gan"] on the command line the bash variable $1 is "my file.gan" while the ganttproject script runs, but the java app tries to open "my" instead of "my files.gan".
Here's the relevant part of the log:
java.io.IOException: Unable to open the file
my
at net.sourceforge.ganttproject.GanttProject.openDocument(GanttProject.java:1897)
at net.sourceforge.ganttproject.GanttProject.open(GanttProject.java:1867)
This is due to two bugs in the ganttproject and ganttproject.sh scripts:
---- Resources ----
Passing parameters with the $* or the $@ does not preserve the spaces and blanks and one parameter becomes two or more if there was a space in it. If one wants to preserve those blanks the "$@" formula needs to be used.
When you launch [ganttproject "my file.gan"] on the command line the bash variable $1 is "my file.gan" while the ganttproject script runs, but the java app tries to open "my" instead of "my files.gan".
Here's the relevant part of the log: IOException: Unable to open the file .ganttproject. GanttProject. openDocument( GanttProject. java:1897) .ganttproject. GanttProject. open(GanttProje ct.java: 1867)
java.io.
my
at net.sourceforge
at net.sourceforge
This is due to two bugs in the ganttproject and ganttproject.sh scripts:
---- ganttproject ----
.ganttproject.sh $@
Fixed:
.ganttproject.sh "$@"
---- ganttproject.sh ---- $LOCAL_ CLASSPATH $BOOT_CLASS $CONFIGURATION_FILE $* >$GP_HOME/ ganttproject. log 2>&1
$JAVA_COMMAND -Xmx256m -classpath $CLASSPATH:
Fixed: $LOCAL_ CLASSPATH $BOOT_CLASS $CONFIGURATION_FILE "$@" >$GP_HOME/ ganttproject. log 2>&1
$JAVA_COMMAND -Xmx256m -classpath $CLASSPATH:
---- Resources ----
Passing parameters with the $* or the $@ does not preserve the spaces and blanks and one parameter becomes two or more if there was a space in it. If one wants to preserve those blanks the "$@" formula needs to be used.
Bug report is filed on Sourceforge for ganttproject.sh: sourceforge. net/tracker/ index.php? func=detail& aid=1983774& group_id= 72728&atid= 535427
http://
Patch is submitted on Sourceforge for ganttproject.sh: sourceforge. net/tracker/ index.php? func=detail& aid=1983778& group_id= 72728&atid= 535429
http://
Patch is attached.
Cheers,
Karoly