Contributing

From Our World of Text Wiki

This page will guide you through the process of contributing to OWOT source code.

Keep in mind that it doesn't include a lot of things you may need to know.

Software Requirements

Git

You will need Git to download the source code, track your changes and get them merged.

Node.js

You will need Node.js to run the server with your changes locally. Our World of Text has been tested on versions as early as v16. If you haven't installed Node.js already, you can go for the LTS release which works fine for essentially everybody.

A Code Editor

Forking the Source Code

In order to make changes to OWOT, you will first have to make your own copy ("fork") of the source code.

  1. Create an account on GitHub if you don't have one already.
  2. Go to the OWOT repo and click the Fork button.
  3. Optionally change the repo name and click Create fork.

Generating a GitHub Access Token

  1. Go here.
  2. Give the token a name and an expiration date of your choice.
  3. Select the repo scope.
  4. Press "Generate token".
  5. Copy your new token and store it securely.

This token allows access to your GitHub account, so make sure not to share it.

Cloning the Source Code

Then, you need to download ("clone") to code to your computer.

  1. Go to your fork's GitHub page
  2. Click the green <> Code button.
  3. Select HTTPS if not already selected.
  4. Copy the URL.
  5. Open the terminal in the folder where you want to store the code.
  6. Enter git clone https://your.url and wait for it to finish.
  7. Enter cd NodeWorldOfText to enter the directory.

Creating a Branch

You will need to create a new Git branch for your changes.

  1. Enter git branch your-branch-name.
  2. Enter git checkout your-branch-name to switch to the new branch.

Making Changes

Now you can open your code editor and make changes to the code.

To commit your changes, first stage them with git add . and then run git commit -m "Your commit message here.".

Pushing Changes

Next, upload ("push") your changes to GitHub with git push --set-upstream origin your-branch-name.

If you get asked for a password, enter your access token.

Creating a Pull Request

Finally, go to your fork's GitHub page and select your new branch.

Click Contribute and Open pull request.

Give the pull request a name and a description and press Create pull request.

Now you can wait for your changes to be merged or declined, which usually happens within a few days.