Skip to content

Commit 8c3cd47

Browse files
author
Lauren McCarthy
committed
Merge branch 'master' of github.com:processing/p5.js-website
2 parents 7574c5d + 6e4e126 commit 8c3cd47

File tree

1 file changed

+19
-23
lines changed

1 file changed

+19
-23
lines changed

contributor_docs/i18n_contribution.md

Lines changed: 19 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -37,40 +37,37 @@ If you want to contribute with p5.js website translations, you are in the right
3737
![processing/p5.js-website repository menu. The "Clone or download" button is pressed and a tab is displayed under it from which the repository's link can be copied.](https://github.com/processing/p5.js-website/raw/master/contributor_docs/assets/clone.png)
3838

3939
4. Open your command-line interface (CLI) and [clone](https://help.github.com/articles/cloning-a-repository/) your fork of the p5.js-website repository to `your_directory` on your laptop by typing:
40-
41-
```bash
40+
```
4241
$ git clone repo_URL
4342
```
4443
4544
5. Go to the repository's directory `[your_directory]/p5.js-website/` and install all the packages and dependencies for the website by typing (if you work on Mac it should be like `Users/[your_user]/[your_directory]/p5.js-website/`):
4645
47-
```bash
46+
```
4847
$ npm install
4948
```
5049
6. Check if the packages are correctly installed by typing:
5150
52-
```bash
51+
```
5352
$ npm run watch
5453
```
5554
5655
7. This should open a window in your browser with the site running at http://localhost:9000.
5756
8. Set `github.com/processing/p5.js-website` as the upstream of your local. Type the following to list the configured remote for your fork (or follow this [tutorial](https://help.github.com/articles/configuring-a-remote-for-a-fork/)):
58-
59-
```bash
57+
```
6058
$ git remote -v
6159
origin https://github.com/YOUR_USERNAME/YOUR_FORK.git (fetch)
6260
origin https://github.com/YOUR_USERNAME/YOUR_FORK.git (push)
6361
```
6462
65-
Then specify a new remote upstream for your fork (don't forget that by doing this you are setting the upstream for your local fork, but not for your fork on Github):
66-
67-
```bash
63+
9. Then specify a new remote upstream for your fork (don't forget that by doing this you are setting the upstream for your local fork, but not for your fork on Github):
64+
```
6865
$ git remote add upstream github.com/processing/p5.js-website
6966
```
7067
71-
Finally verify if your remote upstream has been set (it should look like this):
68+
10. Finally verify if your remote upstream has been set (it should look like this):
7269
73-
```bash
70+
```
7471
$ git remote -v
7572
origin https://github.com/YOUR_USERNAME/YOUR_FORK.git (fetch)
7673
origin https://github.com/YOUR_USERNAME/YOUR_FORK.git (push)
@@ -84,7 +81,7 @@ Finally verify if your remote upstream has been set (it should look like this):
8481
8582
1. Sync your fork to keep it up-to-date with the upstream repository following the next commands or this [tutorial](https://help.github.com/articles/syncing-a-fork/). First fetch the upstream repo and its commits -commits will be stored on your local fork- and then merge changes from upstream to your local:
8683
87-
```bash
84+
```
8885
$ git fetch upstream
8986
$ git merge upstream/master
9087
```
@@ -93,23 +90,22 @@ Finally verify if your remote upstream has been set (it should look like this):
9390
3. Check if your changes are correct and don't break the website render by typing `npm run watch`.
9491
4. Commit the files you have changed, type:
9592
96-
```bash
97-
$ git add -A
93+
```
94+
$ git add -A
9895
$ git commit -m "add a message to your commit"
9996
$ git push
10097
```
10198
10299
5. Commit to your repository at your github account and create a new [Pull Request](https://github.com/processing/p5.js-website/wiki/Pull-requests). Click the *Pull Reques* tab on your fork page and then click the green button *New Pull Request*.
103-
![processing/p5.js-website repository menu. "Pull requests" tab is opened and a green button with the text "New pull request" is displayed a the right bottom of the menu.](https://github.com/processing/p5.js-website/tree/master/contributor_docs/assets/pull_request.png)
100+
![processing/p5.js-website repository menu. "Pull requests" tab is opened and a green button with the text "New pull request" is displayed a the right bottom of the menu.](https://raw.githubusercontent.com/processing/p5.js-website/master/contributor_docs/assets/pull_request.png)
104101
105102
## File Structure
106103
Under this repo there are two directories in which we have to focus:
107-
108-
```
109-
p5.js-website/
110-
src/
111-
dist/
112-
```
104+
```
105+
p5.js-website/
106+
src/
107+
dist/
108+
```
113109
114110
* `dist/`: the actual website is stored under this directory and its files **must never be modified by hand**, they are overwritten each time the web is built.
115111
* `src/`: contains the files from where the page is rendered, which means .hbs and .yml files for the website itself and .js and .json files for Reference and Examples. **All your changes must be done here**.
@@ -126,14 +122,14 @@ Under this repo there are two directories in which we have to focus:
126122
127123
1. Define an abbreviation for your language following the [ISO 639-1](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes) standard. It's expected that abbreviations are two-letter, but for macro languages can be added extra extensions depending on each case.
128124
2. Open a new issue and propose the addition of the new language. If both the proposal and the abbreviation are approved proceed with the next step.
129-
3. Add an entry with the new language abbreviation at `package.json` to the `languages` category -located under the repository root directory.
125+
3. Add an entry with the new language abbreviation at `package.json` to the `languages` category -located under the repository root directory. Please keep the language abbreviations in alphabetical order.
130126
131127
```JSON
132128
"languages": [
133129
"en",
134130
"es",
135131
"zh-Hans",
136-
"new language here"
132+
"new language here (or in correct alphabetical spot)"
137133
],
138134
```
139135

0 commit comments

Comments
 (0)