Commit e13c0a13 authored by Felix Dietrich's avatar Felix Dietrich Committed by Felix Dietrich

Initial commit: Vadere master

parent 540e4f17

Too many changes to show.

To preserve performance only 478 of 478+ files are displayed.

#builds, log/preferences files
target/
*.out
*.preferences.xml
#IntelliJ
.idea/
*.iml
#Eclipse
.settings/
.metadata/
.classpath
.project
#package specific
VadereGui/*.png
VadereGui/*.svg
VadereGui/*.mov
VadereUtils/testreports/*.txt
VadereSimulator/resources/current_commit_hash.txt
  • I fixed the problem. The application will no longer crash if there is no current_commit_hash.txt, instead an error will be logged. I also updated the paths used in the hook files. The user has to copy the hook files into the .git directory. Note that all hooks and the scrip file contained in Documentation/version_control have to be executable. I additionally add a JUnit test that fails if there is no current_commit_hash.txt. All these changes are currently in the develop-branch.

Please register or sign in to reply
#model test output
VadereModelTests/TestOSM/output/*
VadereModelTests/TestSFM/output/*
VadereModelTests/TestGNM/output/*
VadereModelTests/TestOVM/output/*
VadereModelTests/TestOSM/processed output/*
VadereModelTests/TestSFM/processed output/*
VadereModelTests/TestGNM/processed output/*
VadereModelTests/TestOVM/processed output/*
#deprecated: can potentially be removed
bin/
VadereGui/output/
Contribution guidelines
=======================
Coding style guide
------------------
Basic rules:
- No warnings
- No unused imports
- Use the formatting tool!
- Eclipse: select text (optional) and press <kbd>ctrl</kbd> + <kbd>shift</kbd> + <kbd>f</kbd>
- IntelliJ: select text (optional) and <kbd>ctrl</kbd> + <kbd>alt</kbd> + <kbd>l</kbd>
For source code formatting, we use an adapted version of
[Google's Coding style guide](https://google.github.io/styleguide/javaguide.html).
Please check the [README in this repository](/vadere/styleguide)
for the style guide and for how to import the style settings into your IDE.
Commit style guide
------------------
These are examples for a good commit messages:
```
Fix typo in introduction to user guide
```
```
Refactor model initialization
Extracting a new class ModelBuilder because this functionality might be
used in multiple places.
```
Rules:
1. Separate subject from body with a blank line
2. Limit the subject line to 50 characters
3. Capitalize the subject line
4. Do not end the subject line with a period
5. Use the imperative mood in the subject line
6. Wrap the body at 72 characters
7. Use the body to explain what and why vs. how
Source: http://chris.beams.io/posts/git-commit/
This article lists good reasons for each rule!
Reasons include:
- Clean and consistent git-log that also fits in the GitLab user interface
- Stick to Git standards, e.g. "Merge branch ..." and "Revert ..."
Rules 1, 3, and 4 never hurt and should always be applied.
VADERE & Git
============
This document describes our workflows with Git.
## Excursus: Fundamentals of Git remotes
Like we can have multiple branches, we can also have multiple remotes.
Remotes are other repositories we are synchronizing with.
You are probably already familiar with remotes:
When you clone a repository, you have this repository as a remote.
By convention, it is called `origin`.
We use remotes to work with the public and the private VADERE repositories from
only *one* local repository.
Source: Scott Chacon and Ben Straub: [Pro Git](https://git-scm.com/book/en/v2),
specifically [Working with
Remotes in chapter 2](https://git-scm.com/book/en/v2/Git-Basics-Working-with-Remotes)
## Repository setup
Our repositories are set up as follows:
1. A public repository `vadere`.
2. A private repository `vadere-private`.
The public repository contains these branches:
1. `master` for the current stable release.
2. `develop` for current development.
3. `dev/*` or `lastname/*` branches.
For new releases, `develop` is merged into `master`.
The private repository contains only branches that must be private, e.g. a new
simulation model under development. It does not contain copies of any branches
of the public repository because this leads to a synchronization overhead.
Important: Both remote repositories are managed from one single local
repository using remotes. For details, see the workflows below.
The URLs for public and private repositories are:
* git@gitlab.lrz.de:vadere/vadere.git
* git@gitlab.lrz.de:vadere/vadere-private.git
## Workflows
### Getting started & public contribution
For standard development and bugfixes, you can follow this workflow.
```
git clone <url-of-public-repo>
cd vadere
git checkout develop
git checkout -b dev/my-feature
```
With this commands, you
1. make your initial clone of the public repository.
2. checkout the development branch on which we are working.
(The `master` branch is reserved for stable releases.)
3. checkout a new branch (based on `develop`) to work on a new feature.
(Note that the feature branch should start with `dev/` but cannot start with `develop/`.)
After you finished the new feature, go to GitLab, view your feature branch and create a pull/merge request.
The target branch must be `develop`, not `master`.
![Screenshout of GitLab merge request creation (1)](gitlab-merge-request.png)
![Screenshout of GitLab merge request creation (2)](gitlab-merge-request-create.png)
### Working on a private branch
To work on a private project, you can follow this workflow.
If not already done,
1. clone the public repository (see above).
2. add the private repository as a remote: `git remote add private <url-of-private-repo>`
Now proceed with:
```
git checkout master
git checkout -b my-model
git push -u private my-model
```
With this commands, you
1. checkout the current release.
2. checkout a new branch (based on `master`) to work on e.g. a new model.
3. push your new branch to the private repository.
From now, you can synchronize your private branch with `git pull` and `git
push` with the private repository.
### Working together on a private branch
To work together on a private branch, you can follow this workflow.
Precondition: One person has set up a private branch (see previous section).
First, the co-worker has to do this steps (described in the previous section):
1. Clone the public repository.
2. Add the private repository as a remote.
Now, the co-worker proceeds with:
```
git fetch --all
git checkout private/my-model
git checkout -b my-model
git push -u private my-model
```
With this commands, you
1. fetch the latest state of all repositories.
2. checkout the existing private branch of the remote `private`.
3. checkout your "working branch" with the same name but without the `private/` prefix.
4. initially push and register the branch.
From now, you can commit changes into this branch and synchronize with the
private repository using `git pull` and `git push`.
### Rebasing to avoid unnecessary merge commits
You may want to update your local branch you are currently working on and get
the latest changes of `master` or `develop`.
To avoid unnecessary merge commits you should prefer
[rebasing](https://git-scm.com/book/de/v1/Git-Branching-Rebasing) over merging.
Automatic merging happens when you do `git pull` and there are new commits
locally *and* remotely.
In this case it is usually better to do `git pull --rebase`. This applies your
local commits on top of the remote's commits.
Please configure Git to avoid merges on `git pull`:
```
# cd into your vadere repository, then
git config pull.ff only
```
GNU LESSER GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
This version of the GNU Lesser General Public License incorporates
the terms and conditions of version 3 of the GNU General Public
License, supplemented by the additional permissions listed below.
0. Additional Definitions.
As used herein, "this License" refers to version 3 of the GNU Lesser
General Public License, and the "GNU GPL" refers to version 3 of the GNU
General Public License.
"The Library" refers to a covered work governed by this License,
other than an Application or a Combined Work as defined below.
An "Application" is any work that makes use of an interface provided
by the Library, but which is not otherwise based on the Library.
Defining a subclass of a class defined by the Library is deemed a mode
of using an interface provided by the Library.
A "Combined Work" is a work produced by combining or linking an
Application with the Library. The particular version of the Library
with which the Combined Work was made is also called the "Linked
Version".
The "Minimal Corresponding Source" for a Combined Work means the
Corresponding Source for the Combined Work, excluding any source code
for portions of the Combined Work that, considered in isolation, are
based on the Application, and not on the Linked Version.
The "Corresponding Application Code" for a Combined Work means the
object code and/or source code for the Application, including any data
and utility programs needed for reproducing the Combined Work from the
Application, but excluding the System Libraries of the Combined Work.
1. Exception to Section 3 of the GNU GPL.
You may convey a covered work under sections 3 and 4 of this License
without being bound by section 3 of the GNU GPL.
2. Conveying Modified Versions.
If you modify a copy of the Library, and, in your modifications, a
facility refers to a function or data to be supplied by an Application
that uses the facility (other than as an argument passed when the
facility is invoked), then you may convey a copy of the modified
version:
a) under this License, provided that you make a good faith effort to
ensure that, in the event an Application does not supply the
function or data, the facility still operates, and performs
whatever part of its purpose remains meaningful, or
b) under the GNU GPL, with none of the additional permissions of
this License applicable to that copy.
3. Object Code Incorporating Material from Library Header Files.
The object code form of an Application may incorporate material from
a header file that is part of the Library. You may convey such object
code under terms of your choice, provided that, if the incorporated
material is not limited to numerical parameters, data structure
layouts and accessors, or small macros, inline functions and templates
(ten or fewer lines in length), you do both of the following:
a) Give prominent notice with each copy of the object code that the
Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the object code with a copy of the GNU GPL and this license
document.
4. Combined Works.
You may convey a Combined Work under terms of your choice that,
taken together, effectively do not restrict modification of the
portions of the Library contained in the Combined Work and reverse
engineering for debugging such modifications, if you also do each of
the following:
a) Give prominent notice with each copy of the Combined Work that
the Library is used in it and that the Library and its use are
covered by this License.
b) Accompany the Combined Work with a copy of the GNU GPL and this license
document.
c) For a Combined Work that displays copyright notices during
execution, include the copyright notice for the Library among
these notices, as well as a reference directing the user to the
copies of the GNU GPL and this license document.
d) Do one of the following:
0) Convey the Minimal Corresponding Source under the terms of this
License, and the Corresponding Application Code in a form
suitable for, and under terms that permit, the user to
recombine or relink the Application with a modified version of
the Linked Version to produce a modified Combined Work, in the
manner specified by section 6 of the GNU GPL for conveying
Corresponding Source.
1) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (a) uses at run time
a copy of the Library already present on the user's computer
system, and (b) will operate properly with a modified version
of the Library that is interface-compatible with the Linked
Version.
e) Provide Installation Information, but only if you would otherwise
be required to provide such information under section 6 of the
GNU GPL, and only to the extent that such information is
necessary to install and execute a modified version of the
Combined Work produced by recombining or relinking the
Application with a modified version of the Linked Version. (If
you use option 4d0, the Installation Information must accompany
the Minimal Corresponding Source and Corresponding Application
Code. If you use option 4d1, you must provide the Installation
Information in the manner specified by section 6 of the GNU GPL
for conveying Corresponding Source.)
5. Combined Libraries.
You may place library facilities that are a work based on the
Library side by side in a single library together with other library
facilities that are not Applications and are not covered by this
License, and convey such a combined library under terms of your
choice, if you do both of the following:
a) Accompany the combined library with a copy of the same work based
on the Library, uncombined with any other library facilities,
conveyed under the terms of this License.
b) Give prominent notice with the combined library that part of it
is a work based on the Library, and explaining where to find the
accompanying uncombined form of the same work.
6. Revised Versions of the GNU Lesser General Public License.
The Free Software Foundation may publish revised and/or new versions
of the GNU Lesser General Public License from time to time. Such new
versions will be similar in spirit to the present version, but may
differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the
Library as you received it specifies that a certain numbered version
of the GNU Lesser General Public License "or any later version"
applies to it, you have the option of following the terms and
conditions either of that published version or of any later version
published by the Free Software Foundation. If the Library as you
received it does not specify a version number of the GNU Lesser
General Public License, you may choose any version of the GNU Lesser
General Public License ever published by the Free Software Foundation.
If the Library as you received it specifies that a proxy can decide
whether future versions of the GNU Lesser General Public License shall
apply, that proxy's public statement of acceptance of any version is
permanent authorization for you to choose that version for the
Library.
Readme.
\ No newline at end of file
![Vadere](vadere.png "Vadere")
---
# Vadere
Vadere is an open source framework for the simulation of microscopic pedestrian dynamics. In addition to this core domain, other systems including cars and granular flow can be introduced into the framework. Vadere provides generic model classes and visualisation and data analysis tools for two-dimensional systems. A series of simulation models are already implemented in the framework that are also the basis for scientific publications. Namely the optimal steps model, the gradient navigation model, and the social force model are available for simulation studies.
This software runs on OS X, Windows, and Linux.
Vadere has been developed at the Munich University of Applied Sciences at the department for Computer Science and Mathematics. However, we welcome contributions from external sources.
## Installation
### Dependencies
* Java 8
* Maven 3.0
* Git