THM-MoTE / mope-server

Server process for Modelica | Editor
https://thm-mote.github.io//projects/mope
GNU General Public License v3.0
9 stars 0 forks source link

Server-Jar is not platform-independent #1

Closed CSchoel closed 7 years ago

CSchoel commented 7 years ago

The file ProjectInfo.scala is generated by the SBT-script. It contains a config directory that is evaluated based on the home directory of the user which compiles the server. This means that the resulting JAR-file will contain the same path, even if it is used by a different user or on a different operating system.

This is also true for the current release download for version 6.0, which fails on windows with the message Exception in thread "main" java.nio.file.NoSuchFileException: \home\nico\.mope.

We can fix this by evaluating the config dir only at runtime when the server is started. If we want to give the user the possibility to choose a differend config directory, a command line parameter for the server would probably be the right place for this.