Commit 3f535fda authored by David E. DeMarle's avatar David E. DeMarle

Merge branch 'hooks-and-contributing-copy' into 'master'

Copying hooks and from qt-viewer.

See merge request !108
parents 131acd5d ef3a2f02
Pipeline #47408 failed with stage
in 0 seconds
# Test for flake8
which flake8 > /dev/null 2>&1
if [ $? != 0 ]; then
echo 'To enable pep-8 validation install flake8 and then run'
exit 0
files=`git diff --cached --name-only --diff-filter=ACM | grep -e '\.py$'`
if [ -z "$files" ]
exit 0
output=`flake8 $files`
if [ ${status} != 0 ]; then
echo 'PEP8 errors found in commit:'
echo "$output"
exit 0
*.py format.flake8
Contributing to Cinema
This page documents at a very high level how to contribute to Cinema.
This page documents at a very high level how to contribute to Cinema. The
Cinema development cycle is built upon the following components:
1. [Issues][] identify any issues including bugs and feature requests. In
general, every code change should have an associated issue which identifies
the bug being fixed or the feature being added.
For information about setting up a gitlab account and how to fork this project go [here][VTK_contributing] and [here][VTK_develop].
2. [Merge Requests][] are collections of changes that address issues.
Reporting Issues
Cinema development uses a [branchy workflow][branchy] equivalent to [that one used in projects like VTK][VTK_develop], based on a master branch and different topic branches. The master branch always reflects a state with the latest delivered development changes and is the place from where topic branches are branched and merged to. It should always be in a stable state.
If you have a bug report or a feature request for ParaView, you can use the
[Issues][] tracker to report a [new issue][].
To report an issue.
1. Register [GitLab Access] to create an account and select a user name.
2. Create a [new issue][].
3. Ensure that the issue has a **Title** and **Description**
with enough details for someone from the development team to reproduce the
issue. See [Gitlab Markdown] guide for styling the **Description**. Include
screenshots and sample datasets whenever possible.
Fixing issues
Typically, one addresses issues by writing code. To start contributing to a
Cinema project:
1. Register for [GitLab Access] to create an account and select a user name.
2. Fork the relevant repository into your user's namespace on GitLab.
3. Create a local clone of the relevant Cinema repository from your fork.
Optionally configure Git to [use SSH instead of HTTPS][]. For example if
you are working on an issue in the `Cinema/cinema_python` repository:
$ git clone<username>/cinema_python.git cinema_python
4. Create a topic branch and edit files and create commits to resolve the
issue (repeat as needed):
$ edit file1 file2 file3
$ git add file1 file2 file3
$ git commit
Aim for PEP8 style compliance. flake8 should not report any violations in the library.
Commit messages must be thorough and informative so that reviewers will
have a good understanding of why the change is needed before looking at the
code. Appropriately refer to the issue number, if applicable. Cinema
development uses a [branchy workflow][branchy] equivalent to the one used
in projects like [VTK][VTK_develop], based on a master branch and different
topic branches.
Please make sure your python code follows the [PEP 8] style guidelines.
The [flake8] tool is a good way to check for violations. If you run the
`./` after cloning a Cinema repo it will setup pre-commit
checks with flake8 if you have the tool installed.
5. Depending on the repository you are working with run tests with ctest
directly or replace the [vtkcinema_python] submodule in [ParaView] with
your branch and run the Cinema tests in ParaView:
$ ctest -R Cinema
6. Push your commits in your topic branch to your fork in gitlab.
7. [Create a Merge Request][] and solicit feedback from other Cinema developers.
8. Once another Cinema developer has signed off on your changes then you can
have the kwrobot merge your changes:
$ do: merge
[GitLab Access]:
[Gitlab Markdown]:
[use SSH instead of HTTPS]: Documentation/dev/git/
[Merge Requests]:
[new issue]:
[PEP 8]:
[Create a Merge Request]: Documentation/dev/git/
if [ -f $target_file ]; then
echo "Please move current $target_file out of the way first."
ln -s $source_file $target_file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment