You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+25-8Lines changed: 25 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -19,19 +19,20 @@ Please verify that your issue is not being currently addressed by other issues o
19
19
20
20
While issue reporting is valuable, we strongly encourage users who are inclined to do so to submit patches for new or existing issues via pull requests. This is particularly the case for simple fixes, such as typos or tweaks to documentation, which do not require a heavy investment of time and attention.
21
21
22
-
Contributors are also encouraged to contribute new code to enhance PyMC's functionality, also via pull requests. Please consult the [PyMC3 documentation](https://pymc-devs.github.io/pymc3/) to ensure that any new contribution does not strongly overlap with existing functionality.
22
+
Contributors are also encouraged to contribute new code to enhance PyMC3's functionality, also via pull requests. Please consult the [PyMC3 documentation](https://pymc-devs.github.io/pymc3/) to ensure that any new contribution does not strongly overlap with existing functionality.
23
23
24
24
The preferred workflow for contributing to PyMC3 is to fork the [GitHUb repository](https://github.com/pymc-devs/pymc3/), clone it to your local machine, and develop on a feature branch.
25
25
26
26
## Steps:
27
27
28
28
1. Fork the [project repository](https://github.com/pymc-devs/pymc3/) by clicking on the 'Fork' button near the top right of the main repository page. This creates a copy of the code under your GitHub user account.
29
29
30
-
2. Clone your fork of the PyMC3 repo from your GitHub account to your local disk:
30
+
2. Clone your fork of the PyMC3 repo from your GitHub account to your local disk, and add the base repository as a remote:
3. Create a ``feature`` branch to hold your development changes:
@@ -42,20 +43,36 @@ The preferred workflow for contributing to PyMC3 is to fork the [GitHUb reposito
42
43
43
44
Always use a ``feature`` branch. It's good practice to never routinely work on the ``master`` branch of any repository.
44
45
45
-
4. Develop the feature on your feature branch. Add changed files using ``git add`` and then ``git commit`` files:
46
+
4. Project requirements are in ``requirements.txt``, and libraries used for development are in ``requirements-dev.txt``. To set up a development environment, you may (probably in a [virtual environment](http://python-guide-pt-br.readthedocs.io/en/latest/dev/virtualenvs/)) run:
47
+
48
+
```bash
49
+
$ pip install -r requirements.txt
50
+
$ pip install -r requirements-dev.txt
51
+
```
52
+
53
+
Alternatively, there is a script to create a docker environment for development. See: [Developing in Docker](#Developing-in-Docker).
54
+
55
+
5. Develop the feature on your feature branch. Add changed files using ``git add`` and then ``git commit`` files:
46
56
47
57
```bash
48
58
$ git add modified_files
49
59
$ git commit
50
60
```
51
61
52
-
to record your changes in Git locally, then push the changes to your GitHub account with:
62
+
to record your changes locally.
63
+
After committing, it is a good idea to sync with the base repository in case there have been any changes:
64
+
```bash
65
+
$ git fetch upstream
66
+
$ git rebase upstream/master
67
+
```
68
+
69
+
Then push the changes to your GitHub account with:
53
70
54
71
```bash
55
72
$ git push -u origin my-feature
56
73
```
57
74
58
-
5. Go to the GitHub web page of your fork of the PyMC3 repo. Click the 'Pull request' button to send your changes to the project's maintainers fo review. This will send an email to the committers.
75
+
6. Go to the GitHub web page of your fork of the PyMC3 repo. Click the 'Pull request' button to send your changes to the project's maintainers for review. This will send an email to the committers.
59
76
60
77
## Pull request checklist
61
78
@@ -96,8 +113,8 @@ tools:
96
113
* No PEP8 warnings, check with:
97
114
98
115
```bash
99
-
$ pip install pep8
100
-
$ pep8 path/to/module.py
116
+
$ pip install pycodestyle
117
+
$ pycodestyle path/to/module.py
101
118
```
102
119
103
120
* AutoPEP8 can help you fix some of the easy redundant errors:
0 commit comments