- Merge requests should be review from at least one other person
- Only merge yourself if you are absolutely sure it does not break anything
### feature request
## feature request
If you would like to have a new feature, script or module, open an [issue](https://gitlab.phys.ethz.ch/core/python/issues/new).
...
...
@@ -98,7 +93,7 @@ If you would like to have a new feature, script or module, open an [issue](https
- choose **label**: `Feature request`
- submit
### bug report
## bug report
To report a bug, open an [issue](https://gitlab.phys.ethz.ch/core/python/issues/new).
...
...
@@ -107,9 +102,13 @@ To report a bug, open an [issue](https://gitlab.phys.ethz.ch/core/python/issues/
- choose **label**: `Bug`
- submit
### contributing
## contributing
This gitlab repo will be cloned to many locations, and the `master` branch should always be **stable**.
~~Therefore the `master` branch is protected. No one can push to it directly.~~ If you want someone else to review your changes it might be a good workflow to make a pull request (also for documentation purpose)
This gitlab repo will be cloned to many locations, and the `master` branch should always be **stable**. Therefore the `master` branch is protected. No one can push to it directly.
### branching
To contribute create your own **local-<yourname>** branch or a **feature/bugfix** branch:
...
...
@@ -126,6 +125,8 @@ git commit
git push
```
### pull request
Git will show you the link to open a **pull request**:
```
...
...
@@ -142,27 +143,57 @@ You can also go to [branches](https://gitlab.phys.ethz.ch/core/python/branches)
Let someone review it and discuss. **Changes** shows the diff.
### merge
Once it is ready to be merged:
- merge it by clicking the green **Merge** button
- remove source branch now with the **Remove Source Branch** button
Pull the updated `master` branch (which now contains your work):
### pull in feature branch
If you want to continue working in your branch, do:
```
git checkout newfeature
git pull --rebase origin/master
```
### pull in `master` branch
```
git checkout master
```
Pull the updated `master` branch (which now contains your work):
```
git pull
```
You can now also safely remove your feature branch in your own git repo:
A `pull` actually does this:
```
git branch -d newfeature
git fetch origin
git merge origin/master
```
Or of you would like to make another commit in this branch, rebase first:
### rebase branch
If you decide to make another commit in this branch, rebase first:
```
git checkout newfeature
git rebase master
git rebase origin/master
```
This will do a fast-forward merge.
### delete feature branch
You could now also safely remove your feature branch in your own git repo: