Skip to content

Commit 50a91a1

Browse files
author
Joseph Damiba
committed
Update Contributing.md
Update Contributing.md Update Contributing.md Update Contributing.md Update README.md Update Contributing.md Update Contributing.md Update Contributing.md Update Contributing.md Update Contributing.md Update Contributing.md Update Contributing.md Update Contributing.md Update README.md Update README.md Update README.md updating readme typo fixup
1 parent fe454c7 commit 50a91a1

File tree

2 files changed

+202
-170
lines changed

2 files changed

+202
-170
lines changed

Contributing.md

Lines changed: 69 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -1,91 +1,103 @@
1-
# Repo Organization
1+
# Contributing to Plotly's Graphing Libraries Documentation
22

3-
Edit or add files in the `_posts` folder in the [source-design-merge](http://github.com/plotly/documentation/tree/source-design-merge) branch.
3+
Plotly welcomes contributions to its [open-source graphing libraries documentation](https://plot.ly/graphing-libraries) from its community of users.
44

5-
## Clone the Repo and Install Dependencies
5+
The `source-design-merge` branch of this repository hosts a Jekyll application hosted on GitHub Pages that serves Plotly's graphing libraries documentation.
66

7-
1. Clone the repo and then check out the source-design-merge branch:
7+
The index page for the documentation website is located at https://plot.ly/graphing-libraries.
8+
9+
### plotly.js
10+
11+
Please be aware that **only the content of Plotly's JavaScript graphing library documentation** (hosted at https://plot.ly/javascript) is contained in this repository. You can find the content in the `_posts/plotly_js` directory.
12+
13+
For information about editing **plotly.js** documentation [click here](https://github.com/plotly/documentation/blob/readme-updates/_posts/plotly_js/README.md).
14+
15+
### plotly.py
16+
17+
The content for Plotly's Python graphing library documentation (hosted at https://plot.ly/python) **IS NOT** contained in this repository. It is contained in the `plotly.py` repository at https://github.com/plotly/plotly.py/tree/master/doc and is cloned into this repository at build time.
18+
19+
For information about editing **plotly.py** documentation [click here] (https://github.com/plotly/plotly.py/blob/master/doc/README.md).
20+
21+
### plotly.r
22+
23+
The content for Plotly's R graphing library documentation (hosted at https://plot.ly/r) **IS NOT** contained in this repository. It is contained in the `plotly.r-docs` repository at https://github.com/plotly/plotly.r-docs/ and is cloned into this repository at build time.
24+
25+
For information about editing Plotly's **R** documentation [click here](https://github.com/plotly/plotly.r-docs/blob/master/README.md).
26+
27+
**For more information about the build process, inspect the CircleCI configuration file in this repository at https://github.com/plotly/documentation/blob/source-design-merge/.circleci/config.yml.**
28+
29+
## Contribute Quickly to Plotly's JavaScript Graphing Library Documentation
30+
31+
To quickly make a contribution to Plotly's JavaScript graphing libraries documentation, simply submit a pull request with the change you would like to suggest to the `source-design-merge` branch of this repository.
32+
33+
The easiest way to do this is to follow the `Edit this page on GitHub` link at the top right of the page you are interested in contributing to:
34+
35+
![Screen Shot 2020-01-07 at 12 45 39 PM](https://user-images.githubusercontent.com/1557650/71916356-bfe53800-314b-11ea-92b6-eb763037f6d5.png)
36+
37+
**You don't have to worry about breaking the site when you submit a pull request!** This is because your change will not be merged to production immediately. A Plotly team member will first perform a code review on your pull request.
38+
39+
## How To Get The Application Working Locally
40+
41+
For more extensive changes to Ploty's JavaScript documentation, we suggest getting the Jekyll application which builds the site to run locally so that you can test your changes as you develop them.
42+
43+
This involves cloning the repository and installing its dependencies: [Git](https://git-scm.com/), [Ruby]((https://www.ruby-lang.org/en/), [Jekyll](https://jekyllrb.com/), and the [Python `requests` package](https://pypi.org/project/requests/).
44+
45+
1. Use [`git`](https://git-scm.com/) to [clone](https://git-scm.com/docs/git-clone) the public `plotly/documentation` repository. Then [check out] (https://git-scm.com/docs/git-checkout) the source-design-merge branch of the `git` repository.
46+
47+
To do so, run the following commands in your terminal:
848

949
```sh
1050
git clone git@github.com:plotly/documentation.git
1151
git fetch origin
1252
git checkout source-design-merge
1353
```
1454

15-
2. Check Ruby version `$ ruby --version`. We recommend using `version 2.3.3` or the same ruby version as [gh-pages](https://pages.github.com/versions/). Note [RVM](https://rvm.io/rvm/install) is helpful for installing and managing ruby versions.
16-
17-
3. Install bundler and dependencies from the `Gemfile`:
55+
Running `git status` in your terminal should then output the following:
1856

1957
```sh
20-
gem install bundler
21-
bundle install
58+
On branch source-design-merge
59+
Your branch is up to date with 'origin/source-design-merge'.
60+
61+
nothing to commit, working tree clean
2262
```
2363

24-
Note these dependencies should be the same version that [gh-pages](https://pages.github.com/versions/) is using.
64+
2. Download Ruby and check your `Ruby` version by running the `ruby --version` command in your terminal.
2565

26-
4. When we deploy, a function is run to update the plot schema. To do this successfully you have to make sure you have the `requests` python package: `pip install requests`
66+
We recommend using `version 2.3.3` or the same ruby version as [gh-pages](https://pages.github.com/versions/). Note [RVM](https://rvm.io/rvm/install) is helpful for installing and managing ruby versions.
2767

28-
## Making Changes
68+
3. Download Jekyll and check your Jekyll version by running the `jekyll -v` command in your terminal. We recommend using the same ruby version as [gh-pages](https://pages.github.com/versions/).
2969

30-
- For information about editing **plotly.js** docs see: https://github.com/plotly/documentation/blob/source-design-merge/_posts/plotly_js/README.md
31-
- For information about editing **python** docs see: https://github.com/plotly/documentation/blob/source-design-merge/_posts/python/README.md
32-
- For information about editing **R** docs see: https://github.com/plotly/documentation/blob/source-design-merge/_posts/r/README.md
33-
- For information about editing chart studio documentation found at [https://help.plot.ly/tutorials/](https://help.plot.ly/tutorials/) please see this repo: [https://github.com/plotly/plotly.github.io](https://github.com/plotly/plotly.github.io)
70+
4. Install bundler and dependencies from the Jekyll applicaton's [`Gemfile`](https://github.com/plotly/documentation/blob/source-design-merge/Gemfile) by running the following commands in your terminal:
71+
72+
```sh
73+
gem install bundler
74+
bundle install
75+
```
3476

35-
## Render Changes Locally
77+
Note these dependencies should be the same version that [gh-pages](https://pages.github.com/versions/) is using.
3678

37-
Please **ALWAYS** locally serve the docs and check your changes before committing updates.
79+
5. When Plotly deploys its graphing libraries documentation to GitHub pages, a function is run to simultaneously update the graphing libraries plot schema in order to keep the two in sync. To do this successfully you have to make sure you have Python and the `requests` Python package installed in your local development environment: `pip install requests`.
3880

39-
1. To serve the docs locally, in the documentation repo run: `bundle exec jekyll serve --config _config_dev.yml`
40-
2. Visit the pages at: [http://localhost:4000/python/](http://localhost:4000/python/)
41-
3. When you make changes, jekyll should automatically regenerate for you. Read the messages in your terminal to check it out
81+
6. Serve the Jekyll application: `bundle exec jekyll serve --config _config_dev.yml`.
82+
7. Visit the pages at: [http://localhost:4000/](http://localhost:4000)
83+
8. When you make changes, Jekyll should automatically regenerate the application for you. Read the messages in your terminal to check it out.
4284

43-
There are a TON of posts in here, so rendering can take up to
44-
thirty minutes! You can *limit* the number of posts that render by
45-
excluding folders in the `_config_dev.yml` file.
85+
There are a TON of posts in here, so rendering can take up to thirty minutes! You can *limit* the number of posts that render by [excluding folders](https://jekyllrb.com/docs/configuration/options/) from being served using custom Jekyll configuration options.
4686

47-
For example, change `_config_dev.yml` to this:
87+
To do so, create a `_config_personal.yml` file:
4888

4989
```yml
5090
staticurl: http://localhost:4000/all_static
51-
exclude: [_posts/ggplot2, _posts/julia, _posts/matlab, _posts/matplotlib, _posts/nodejs, _posts/r] # [_posts/python,]
91+
exclude: [_posts/ggplot2, _posts/julia, _posts/matlab, _posts/matplotlib, _posts/nodejs, _posts/r, posts/python] # [_posts/plotly_js,]
5292
```
5393
54-
and you'll only load the files in `_posts/python`.
94+
and you'll only load the files in `_posts/plotly_js`.
5595

56-
Change it to this
96+
Change it to this:
5797

5898
```yml
5999
staticurl: http://localhost:4000/all_static
60100
exclude: []
61101
```
62102

63-
and it'll load everything.
64-
65-
## Make a PR
66-
Ready for your changes to be reviewed? Make a pull request against the `source-design-merge` branch!
67-
Create a feature branch and use `git status` to list changed files.
68-
69-
(Make sure that the feature branch is a branch off from `source-design-merge` local branch in your machine and not from any other previously worked branch).
70-
```sh
71-
git checkout -b your_feature_branch
72-
git status
73-
```
74-
Add, commit, and push the files that you'd like to add to your pr:
75-
```sh
76-
git add file-a
77-
git add file-b
78-
git commit -m 'message about your changes'
79-
git push origin your_feature_branch
80-
```
81-
Visit the [documentation repo](https://github.com/plotly/documentation) and open a pull request against the `source-design-merge` branch.
82-
83-
After your PR has been reviewed and approved, you can merge it into the `source-design-merge` branch! Your changes haven't been deployed yet so they won't be online. That said, be sure to check them after they have been deployed.
84-
85-
## Search
86-
87-
We now have search via algolia implemented on our index and reference documentation pages! Please refer to our [make README](https://github.com/plotly/documentation/blob/source-design-merge/make_instructions.txt) for more information on how search works and instructions on how to update or edit Plotly search indices.
88-
89-
## Style Edits
90-
91-
Please refer to our [Styles README](https://github.com/plotly/documentation/blob/source-design-merge/style_README.md)
103+
and it'll load everything.

0 commit comments

Comments
 (0)