-
Notifications
You must be signed in to change notification settings - Fork 179
faq 185696257
by Jishnu Narayan on 2018-02-23 10:21:51
Hello all,
Is there a tutorial or documentation available as to how to run a MatSim code as a shell script/ or in command prompt (without using Eclipse)? Any help would be deeply appreciated!
Thank you!
by Johan W. Joubert on 2018-02-23 10:44:36
Hi Jishnu, it will likely depend on whether you refer to MATSim as a checked out copy of the development version or the latest release. The latest release is easier (I cannot seem to find the documentation on the web for it):
Download and unzip the matsim-0.9.0.zip release version.
Change directory into the unzipped folder.
-
Execute the following Java command (adapted from Sections 2.1.2 and 2.1.3 of the MATSim Book):
java -cp matsim-0.9.0.jar org.matsim.run.Controler examples/equil/config.xml
to run the built-in equil
example.
by Kai Nagel on 2018-02-24 08:37:37
Seems that the question was about how to run extensions from the command line. https://matsim.org/extensions has a link to a "corresponding section in the user documentation" (which I will not repeat here since it is going to change).
And yes, you will need jar files (or, possibly, class files) to run from the command line; just having java files will not be enough.
Given the current status of the code, I would advise against using extensions from the command line. It is technically possible, but too hard. Either use core matsim by double-clicking on the jar file. Or use extensions by cloning matsim-example-project into an IDE, and then look at matsim-code-examples for examples how to plug stuff together.
We will try to point out a maven way to use extensions from the command line. But we ain't there yet.
by Jishnu Narayan on 2018-02-26 09:48:53
Dear Kai,
Yes the question was indeed about running extensions from the command line. Thank you for the reply!
You are viewing an archive of the previous MATSim Q&A site. The real site is now at https://matsim.org/faq