Skip to content

Commit 790e1d3

Browse files
DanielGoldfarbDaniel Goldfarb
authored andcommitted
Update CONTRIBUTING.md
1 parent 00966d3 commit 790e1d3

File tree

1 file changed

+30
-3
lines changed

1 file changed

+30
-3
lines changed

CONTRIBUTING.md

Lines changed: 30 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,36 @@
1-
- Contributing can as simple as **asking questions**, participating in discussions, suggesting enhancements, etc. **All of these are valuable!** There are many ways to contribute.
1+
## Contributing Basics
22

3-
- All of the usual/typical open source contribution guidelines apply (see for example, **[Matplotlib Contributing](https://matplotlib.org/3.1.1/devel/contributing.html)** and **[Open Source Guide to Contributing](https://opensource.guide/how-to-contribute/)**). Therefore, here, on this page, we will mention just a few items that we may be particular about in **mplfinance**.
3+
- Contributing can be as simple as **asking questions**, participating in discussions, suggesting enhancements, etc. **All of these are valuable!** There are many ways to contribute. We also very much appreciate when you share the creative things you've done *using* mplfinance (both code and plot images). And, of course, writing code for mplfinance is also a great way to contribute. Thank you.
44

5+
- All of the usual/typical open source contribution guidelines apply (see for example, **[Matplotlib Contributing](https://matplotlib.org/stable/devel/contributing.html)** and **[Open Source Guide to Contributing](https://opensource.guide/how-to-contribute/)**). Therefore, here, on this page, we will mention just a few items that we may be particular about in **mplfinance**.
56

6-
- Coding:
7+
---
8+
9+
## Fork Clone Workflow
10+
- The standard workflow for contributing on GitHub is called **Fork/Clone**. For those who may not be familiar, here is a brief summary and some reference links.
11+
- *We assume you are familiar with **git** basics: `git clone`, `git commit`, etc*.
12+
- Note: a "Fork" is just a `git clone` *that is created on, and that lives on, GitHub*. You create a fork using the **Fork** button on GitHub: This allows GitHub to track the relationship between the original github repository, and your Fork.
13+
- The basic workflow is:
14+
1. Create a **Fork** of the mplfinance repository. (See references below for details.) The fork will exist under *your* github account.
15+
2. **Clone** *your* Fork to your local machine (`git clone`).
16+
3. Work on your cloned copy of the repository, `git commit` the changes, and then **`git push`** them *to your GitHub fork*.
17+
4. When you are satisfied with the code in your fork then, **on the GitHub page for your fork, *open a Pull Request (PR)***. A Pull Request effectively asks for the changes in your fork be pulled into the main mplfinance repository. The PR provides, on github, a place to see the changes, and to post comments and discussion about them.
18+
5. After code review, if you are asked by a maintainer to make additional changes, you do *not* have to re-enter another Pull Request (as long as the original PR is still open). Rather, make the changes in your local clone, and simply `git push` them to your fork again. The changes will automatically flow into the open Pull Request.
19+
6. When done, the maintainer of the repository will merge the changes from your fork into the mplfinance repository. The PR will automatically be closed. (Your fork, however, will continue to exist, and can be used again for additional Pull Requests in the future; See GitHub documentation for how to keep your Fork up to date).
20+
21+
- Some References:
22+
- GitHub documentation:
23+
- **https://docs.github.com/en/get-started/quickstart/contributing-to-projects**
24+
- and some user gists:
25+
- https://gist.github.com/Chaser324/ce0505fbed06b947d962
26+
- https://gist.github.com/rjdmoore/ed014fba0ee2c7e75060ccd01b726cb8
27+
28+
---
29+
30+
## Coding Standards
31+
- I am not super strict about adhearing to every aspect of PEP 8, *nor am I lenient*. I tend to walk the middle of the road: If something is a good and common, then it should be adheared to.
32+
- Here are a few items that I (perhaps uniquely) tend to care about in particular:
733
- If you write code, please don't use tabs; rather use spaces.
834
- If you add a significant feature --that is, a feature for which explaining its usage takes more than just a few sentences-- please also create a "tutorial notebook" for that feature. **[For examples of tutorial notebooks, please see the jupyter notebooks in the examples folder.](https://github.com/matplotlib/mplfinance/tree/master/examples)**
935
- If you add a significant feature, please also create a regression test file **[in the tests folder](https://github.com/matplotlib/mplfinance/tree/master/tests)**, similar to the other regression tests that are there. *Often, the simplest way to do this is to take a few of the examples from the feature's "tutorial notebook"* (see previous point).
36+
- If you work on a pre-existing code file, please try to more-or-less emulate the style that already exists in that file.

0 commit comments

Comments
 (0)