Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: 'Source Code' content in 'Set up Development Environment' page #16780

Merged
merged 2 commits into from Jan 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
29 changes: 26 additions & 3 deletions docs/src/contribute/development-environment.md
Expand Up @@ -15,10 +15,16 @@ Go to <https://nodejs.org/> to download and install the latest stable version fo

Most of the installers already come with [npm](https://www.npmjs.com/) but if for some reason npm doesn't work on your system, you can install it manually using the instructions on the site.

## Step 2: Fork and checkout your own ESLint repository
## Step 2: Fork and Checkout Your Own ESLint Repository

Go to <https://github.com/eslint/eslint> and click the "Fork" button. Follow the [GitHub documentation](https://help.github.com/articles/fork-a-repo) for forking and cloning.

Clone your fork:

```shell
git clone https://github.com/<Your Github Username>/eslint
```

Once you've cloned the repository, run `npm install` to get all the necessary dependencies:

```shell
Expand All @@ -28,7 +34,9 @@ npm install

You must be connected to the Internet for this step to work. You'll see a lot of utilities being downloaded.

## Step 3: Add the upstream source
**Note:** It's a good idea to re-run `npm install` whenever you pull from the main repository to ensure you have the latest development dependencies.

## Step 3: Add the Upstream Source

The *upstream source* is the main ESLint repository where active development happens. While you won't have push access to upstream, you will have pull access, allowing you to pull in the latest code whenever you want.

Expand Down Expand Up @@ -56,7 +64,7 @@ npm install -g generator-eslint

Please see the [generator documentation](https://github.com/eslint/generator-eslint) for instructions on how to use it.

## Step 5: Run the tests
## Step 5: Run the Tests

Running the tests is the best way to ensure you have correctly set up your development environment. Make sure you're in the `eslint` directory and run:

Expand All @@ -68,6 +76,21 @@ The testing takes a few minutes to complete. If any tests fail, that likely mean

## Reference Information

### Directory Structure

The ESLint directory and file structure is as follows:

* `bin` - executable files that are available when ESLint is installed
* `conf` - default configuration information
* `docs` - documentation for the project
* `lib` - contains the source code
* `formatters` - all source files defining formatters
* `rules` - all source files defining rules
* `tests` - the main unit test folder
* `lib` - tests for the source code
* `formatters` - tests for the formatters
* `rules` - tests for the rules

### Workflow

Once you have your development environment installed, you can make and submit changes to the ESLint source files. Doing this successfully requires careful adherence to our [pull-request submission workflow](./pull-requests).
Expand Down
4 changes: 0 additions & 4 deletions docs/src/contribute/index.md
Expand Up @@ -34,10 +34,6 @@ If you'd like to request a change other than a bug fix or new rule, this section

Learn about the architecture of the ESLint project.

## [Get the Source Code](source-code)

Before you can get started developing ESLint, you'll need to get a copy of the ESLint source code. This section explains how to do that and a little about the source code structure.

## [Set up a Development Environment](development-environment)

Developing for ESLint is a bit different than running it on the command line. This section shows you how to set up a development environment and get you ready to write code.
Expand Down
51 changes: 0 additions & 51 deletions docs/src/contribute/source-code.md

This file was deleted.