Skip to content

Commit

Permalink
Documentation edits (#2675)
Browse files Browse the repository at this point in the history
* Remove misspelling

* General documentation edits

* Attempted to expand on main USP

* Mention alternative languages

* Expand on bot

* Update LANGUAGES.md

* Update README.md

Co-authored-by: Evan <64989416+Ferotiq@users.noreply.github.com>
  • Loading branch information
DanGonite57 and Ferotiq authored Mar 12, 2022
1 parent 6a237df commit a615c68
Show file tree
Hide file tree
Showing 6 changed files with 63 additions and 58 deletions.
18 changes: 9 additions & 9 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@ While most contributions don't require that you install dependencies, there are

#### Text Editor

If you are not a developer and wish to contribute themes, new languages, or quotes, having a text editor will make contributions _much_ easier. To make complex edits without installing anything, we recommend using GitHub's VS Code web editor. In your fork of Monkeytype(fork it first), go to the `Code` tab of the repo and press <kbd>.</kbd>(the period/dot key). This will open up the repo in an online VS Code instance you can use to edit files in the browser. Once you are done making your changes, go the to Source Control tab in the activity bar with <kbd>Ctrl/Cmd + Shift + G</kbd>, click the `+` next to the files you've changed to stage them,type a brief message summarizing the changes made in the commit, and press <kbd>Ctrl/Cmd + Enter</kbd> to commit your changes to your fork(send a pull request to the Monkeytype repository when you are ready).
If you are not a developer and wish to contribute themes, new languages, or quotes, having a text editor will make contributions _much_ easier. To make complex edits without installing anything, we recommend using GitHub's VS Code web editor. In your fork of Monkeytype (fork it first), go to the `Code` tab of the repo and press <kbd>.</kbd>(the period/dot key). This will open up the repo in an online VS Code instance you can use to edit files in the browser. Once you are done making your changes, go to the Source Control tab in the activity bar with <kbd>Ctrl/Cmd + Shift + G</kbd>, click the `+` next to the files you've changed to stage them, type a brief message summarizing the changes made in the commit, and press <kbd>Ctrl/Cmd + Enter</kbd> to commit your changes to your fork. Finally, send a pull request to the Monkeytype repository when you are ready.

#### Git

Git is optional but we recommend you utilize it. Monkeytype uses the Git source control management system (SCM) for its version control. Assuming you don't have experience typing commands in the command line, we suggest installing [Sourcetree](https://www.sourcetreeapp.com/). You will be able to utilize the power of Git without needing to remember any cryptic commands. However using a Git client won't give you access to the full functionality of Git but provides an easy to understand graphical user interface (GUI). Once you have downloaded Sourcetree, run the installer. While installing Sourcetree, keep your eyes peeled for the option to also install Git with Sourcetree. This is the option you will need to look for in order to install Git. **Make sure to click yes in the installer to install Git with Sourcetree.**
Git is optional but we recommend you utilize it. Monkeytype uses the Git source control management (SCM) system for its version control. Assuming you don't have experience typing commands in the command line, we suggest installing [Sourcetree](https://www.sourcetreeapp.com/). You will be able to utilize the power of Git without needing to remember any cryptic commands. Using a Git client such as Sourcetree won't give you access to the full functionality of Git, but provides an easy to understand graphical user interface (GUI). Once you have downloaded Sourcetree, run the installer. While installing Sourcetree, keep your eyes peeled for the option to also install Git with Sourcetree. This is the option you will need to look for in order to install Git. **Make sure to click yes in the installer to install Git with Sourcetree.**

#### NodeJS and NPM

Expand Down Expand Up @@ -78,31 +78,31 @@ Alternatively, if you use `nvm` then you can run `nvm install` and `nvm use` (yo

#### Mongo Setup

Follow these steps if you want to work on anything involving the database/account system. If not, you can skip this section.
Follow these steps if you want to work on anything involving the database/account system. Otherwise, you can skip this section.

1. Install [MongodDB Community Edition](https://docs.mongodb.com/manual/administration/install-community/) and ensure that it is running
1. Install [MongoDB Community Edition](https://docs.mongodb.com/manual/administration/install-community/) and ensure that it is running

1. Inside the backend folder, copy `example.env` to `.env` in the same directory.

1. If necessary, uncomment the lines in the `.env` file to use credentials to login to MongoDB.

1. Optional - Install [MongoDB-compass](https://www.mongodb.com/try/download/compass?tck=docs_compass). This tool can be used to see and manipulate your data visually.
1. To connect, type `mongodb://localhost:27017` in the connection string box and press connect. The monkeytype database will be created and shown` after the server is started`.
1. To connect, type `mongodb://localhost:27017` in the connection string box and press connect. The monkeytype database will be created and shown after the server is started.

## Building and Running Monkeytype

Once you have completed the above steps, you are ready to build and run Monkeytype.

1. Run `npm run install:all` in the project root to install all dependencies.
- If you are on Windows, use `npm run install:windows`.
- If none of this works, you will have to run `npm install` in root, frontend, and backend directories.
- If neither works, you will have to run `npm install` in root, frontend, and backend directories.
2. Run `npm run start:dev` (`npm run start:dev:fe` if you skipped the mongo section) to start a local dev server on [port 5000](http://localhost:5000). It will watch for changes and rebuild when you edit files in `src/` or `public/` directories. Note that rebuilding doesn't happen instantaneously so be patient for changes to appear. Use <kbd>Ctrl+C</kbd> to kill it.

**Mac Users:** If you get 403 Forbidden errors while trying to access the local server, go into System Preferences > Sharing and disable AirPlay Receiver - it also runs on port 5000 and takes priority, causing 403 errors.

## Standards and Guidelines

Code style is enforced by [Prettier](https://prettier.io/docs/en/install.html), which automatically runs every time you make a commit(`git commit`) (if you've followed the above instructions properly).
Code style is enforced by [Prettier](https://prettier.io/docs/en/install.html), which automatically runs every time you make a commit (`git commit`) (if you've followed the above instructions properly).

We recommend following the guidelines below to increase your chances of getting your change accepted.

Expand All @@ -117,7 +117,7 @@ Before submitting a theme make sure...
- your theme has been added to the `_list` file and the `textColor` property is the theme's main color
- your theme is clear and readable with both `flip test colors` and `colorful mode` enabled and disabled

(If you want to contribute themes but don't know how to, check [THEMES.md](https://github.com/Miodec/monkeytype/blob/master/THEMES.md))
(If you want to contribute themes but don't know how, check [THEMES.md](https://github.com/Miodec/monkeytype/blob/master/THEMES.md))

#### Language Guidelines

Expand All @@ -126,7 +126,7 @@ Before submitting a theme make sure...
- Be sure to add your language to the `_list` and `_groups` files
- Make sure the number of words in the file corresponds to the file name (for example: `languageName.json` is 200 words, `languageName_1k.json` is 1000 words, and so on)

(If you want to contribute languages but don't know how to, check [LANGUAGES.md](https://github.com/Miodec/monkeytype/blob/master/LANGUAGES.md))
(If you want to contribute languages but don't know how, check [LANGUAGES.md](https://github.com/Miodec/monkeytype/blob/master/LANGUAGES.md))

#### Quote Guidelines

Expand Down
45 changes: 28 additions & 17 deletions LANGUAGES.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,21 @@
### **Table of Contents**

- [Forking Monkeytype](#forking-monkeytype)
- [Creating Languages](#creating-langauges)
- [Commiting Langauges](#commiting-languages)
- [Creating Languages](#creating-languages)
- [Committing Languages](#committing-languages)
- [Language Guidelines](#language-guidelines)

### Forking Monkeytype

First you will have to copy the Monkeytype repository also known as forking. Go to the [Monkeytype Repo](https://github.com/Miodec/monkeytype/) and then click the "fork" button.
First you will have to make a personal copy of the Monkeytype repository, also known as "forking". Go to the [Monkeytype repo](https://github.com/Miodec/monkeytype/) and then click the "fork" button.

<img width="1552" alt="Screen Shot 2022-01-12 at 11 51 49 AM" src="https://user-images.githubusercontent.com/83455454/149194972-23343642-7a1f-4c0c-b5f2-36f4b39a2639.png">
<img width="1552" alt="Screenshot showing location of the fork button on GitHub." src="https://user-images.githubusercontent.com/83455454/149194972-23343642-7a1f-4c0c-b5f2-36f4b39a2639.png">

## Creating Langauges
## Creating Languages

Once you have forked the repository you can now add your langauge. (If you haven't already forked the repository, refer to this [section](#forking-the-repository).) Create a file in `./frontend/static/languages/`. Create a json file with the language name and the amount of words. e.g `language_1k.json`. The minimum amount of words needed are 200 and if that is the amount of words you chose to add then ignore the `_1k` part of the name. Otherwise the name should look something like this: `language_1k.json`. The inside of the file should look like this:
Once you have forked the repository you can now add your language. Create a new json file in `./frontend/static/languages/`, named as the language name and the number of words, e.g. `language_1k.json`. If there are less than 1,000 words, simply name the file after the language (e.g. `language.json`). Note that a minimum of 200 words are required.

The contents of the file should be as follows:
```
{
"name": "language",
Expand All @@ -26,17 +27,28 @@ Once you have forked the repository you can now add your langauge. (If you haven
}
```

(It is recommended that you familiarize yourselves with JSON before adding a language.) For the name varible put the name of your language. Left to right indicates how the language is written. If it is written left to right then put `true` otherwise put false. For bcp47 put your languages IETF language tag. (For more information about the IETF language tag refer to [here]("https://en.wikipedia.org/wiki/IETF_language_tag").) But you aren't done just yet. You need to add your language to the `_groups.json` and `_list.json` files.
Add the name of the language to the `_groups.json` file like so:
It is recommended that you familiarize yourselves with JSON before adding a language. For the `name` field, put the name of your language. `leftToRight` indicates how the language is written. If it is written left to right then put `true`, otherwise put `false`. For `bcp47` put your languages [IETF language tag](https://en.wikipedia.org/wiki/IETF_language_tag). Finally, add your list of words to the `words` field.

In addition to the language file, you need to add your language to the `_groups.json` and `_list.json` files in the same directory. Add the name of the language to the `_groups.json` file like so:

```
{
"name": "language",
"languages": ["language"]
}
"name": "spanish",
"languages": ["spanish", "spanish_1k", "spanish_10k"]
},
{
"name": "YOUR_LANGUAGE",
"languages": ["YOUR_LANGUAGES"]
},
{
"name": "french",
"languages": ["french", "french_1k", "french_2k", "french_10k"]
},
```

And add your language to the `_list.json` file like so:
The `languages` field is the list of files that you have created for your language (without the `.json` file extension). Make sure to add all your files if you have created multiple word lists of differing length in the same language.

Add your language lists to the `_list.json` file like so:

```
,"spanish"
Expand All @@ -48,16 +60,15 @@ And add your language to the `_list.json` file like so:
,"french_2k"
```

### Commiting Languages
### Committing Languages

Once you have created your language you now need to create a pull request on the main Monkeytype repository. Go to the branch where you created your languages on GitHub.
Then make sure your branch is up to date. Once it is up to date click contribute.
Once you have created your language, you now need to create a pull request to the main Monkeytype repository. Go to the branch where you created your languages on GitHub. Then make sure your branch is up to date. Once it is up to date, click "contribute".

Update branch:
<img width="1552" alt="Screen Shot 2022-01-12 at 10 55 19 AM" src="https://user-images.githubusercontent.com/83455454/149186547-5b9fe4fd-b944-4eed-a959-db43f96198bf.png">
<img width="1552" alt="Screenshot showing how to update the fork to match the main Monkeytype repository" src="https://user-images.githubusercontent.com/83455454/149186547-5b9fe4fd-b944-4eed-a959-db43f96198bf.png">

Create a pull request:
<img width="1552" alt="Screen Shot 2022-01-12 at 10 56 42 AM" src="https://user-images.githubusercontent.com/83455454/149186637-66dae488-05ae-45c4-9217-65bc36c4927b.png">
<img width="1552" alt="Screenshot showing how to create a pull request to the main Monkeytype repository" src="https://user-images.githubusercontent.com/83455454/149186637-66dae488-05ae-45c4-9217-65bc36c4927b.png">

## Language Guidelines

Expand Down
23 changes: 11 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,38 +10,37 @@

# About

Monkeytype is a minimalistic and customizable typing test. It features many test modes, an account system to save your typing speed history, and user-configurable features like themes, sounds, a smooth caret, and more.
Monkeytype is a minimalistic and customizable typing test. It features many test modes, an account system to save your typing speed history, and user-configurable features such as themes, sounds, a smooth caret, and more. Monkeytype attempts to emulate the experience of natural typing during a typing test, by unobtrusively presenting the text prompts and displaying typed characters in-place, providing straightforward, real-time feedback on typos, speed, and accuracy.

# Features

- minimalistic design with optional ads
- look at what you are typing
- focus mode
- different test modes
- punctuation mode
- themes
- minimalistic design, with optional advertisements and focus mode while typing
- type what you see, see what you type
- live errors, wpm, and accuracy displays
- variety of test lengths and languages
- punctuation and numbers modes
- quotes
- live wpm
- themes
- smooth caret
- account system
- command line
- challenges and just-for-fun test modifiers
- and much more

# Discord bot

On the [Monkeytype Discord server](https://www.discord.gg/monkeytype), we added a Discord bot to auto-assign roles on our server. You can find its code over at https://github.com/Miodec/monkey-bot
On the [Monkeytype Discord server](https://www.discord.gg/monkeytype), we added a Discord bot to auto-assign optional roles based on typing performance and challenge completion. You can find its code over at https://github.com/Miodec/monkey-bot.

# Bug report or Feature request

If you encounter a bug or have a feature request, [send us an email](jack@monkeytype.com), [create an issue](https://github.com/Miodec/monkeytype/issues), [create a discussion thread](https://github.com/Miodec/monkeytype/discussions), or [join the Discord server](https://www.discord.gg/monkeytype).

# Want to Contribute?

Refer to [CONTRIBUTING.md.](https://github.com/Miodec/monkeytype/blob/master/CONTRIBUTING.md)
Refer to [CONTRIBUTING.md](https://github.com/Miodec/monkeytype/blob/master/CONTRIBUTING.md).

# Code of Conduct

Before contributing to this repository, please read the [code of conduct.](https://github.com/Miodec/monkeytype/blob/master/CODE_OF_CONDUCT.md)
Before contributing to this repository, please read the [code of conduct](https://github.com/Miodec/monkeytype/blob/master/CODE_OF_CONDUCT.md).

# Credits

Expand Down
2 changes: 1 addition & 1 deletion SECURITY.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ We take the security and integrity of Monkeytype very seriously. If you have fou

### Reporting a Vulnerability

For vulnerabilities that impact the confidentiality, integrity, and availability of Monkeytype services, please send your disclosure via (1) [email](jack@monkeytype.com), or (2) private Discord chat to Miodec(Miodec#1512). For non-security related platform bugs, follow the bug submission [guidelines](https://github.com/Miodec/monkeytype#bug-report-or-feature-request). Include as much detail as possible to ensure reproducibility. At a minimum, vulnerability disclosures should include:
For vulnerabilities that impact the confidentiality, integrity, and availability of Monkeytype services, please send your disclosure via (1) [email](jack@monkeytype.com), or (2) private Discord chat to Miodec (Miodec#1512). For non-security related platform bugs, follow the bug submission [guidelines](https://github.com/Miodec/monkeytype#bug-report-or-feature-request). Include as much detail as possible to ensure reproducibility. At a minimum, vulnerability disclosures should include:

- Vulnerability Description
- Proof of Concept
Expand Down
Loading

0 comments on commit a615c68

Please sign in to comment.