Skip to content

docs: improve contributor experience with setup guide and enhanced gitignore #39247

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -56,3 +56,37 @@ docs-internal-data/

# For intermediate data (like scraping for Elasticsearch indexing)
tmp/

# Additional common files to ignore
*.log
*.pid
*.seed
*.pid.lock
.npm
.nyc_output
.grunt
bower_components
.lock-wscript
build/Release
.coverage
.nyc_output
.cache
.parcel-cache
.next
out
dist
.nuxt
.vuepress/dist
.serverless
.fusebox
.dynamodb
.tern-port

# OS generated files
.DS_Store
.DS_Store?
._*
.Spotlight-V100
.Trashes
ehthumbs.db
Thumbs.db
68 changes: 68 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
# Contributing to GitHub Docs

Thank you for your interest in contributing to GitHub Docs! 🎉

## Quick Start for Contributors

### First-time Setup

1. **Fork and clone the repository**
```bash
git clone https://github.com/YOUR-USERNAME/docs.git
cd docs
```

2. **Install dependencies**
```bash
npm install
```

3. **Start the development server**
```bash
npm run dev
```

### Making Changes

1. **Create a new branch**
```bash
git checkout -b your-feature-branch
```

2. **Make your changes**
- Edit content in the `content/` directory
- Test your changes locally with `npm run dev`

3. **Test your changes**
```bash
npm test
npm run lint
```

4. **Commit and push**
```bash
git add .
git commit -m "Brief description of your changes"
git push origin your-feature-branch
```

5. **Create a Pull Request**
- Go to GitHub and create a PR from your fork

## Easy First Contributions

- Fix typos in documentation
- Improve code examples
- Add missing installation steps
- Update outdated links
- Improve formatting and readability

## Need Help?

- Check the detailed [contributing guide](contributing/README.md)
- Browse [help wanted issues](https://github.com/github/docs/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22)
- Read the [content style guide](contributing/content-style-guide.md)

## Code of Conduct

Please note that this project is released with a [Code of Conduct](.github/CODE_OF_CONDUCT.md). By participating in this project you agree to abide by its terms.
36 changes: 36 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,42 @@ This repository contains the documentation website code and Markdown source file

GitHub's Docs team works on pre-production content in a private repo that regularly syncs with this public repo.

## Prerequisites

- **Node.js**: Version 20 or 22 (see [engines](package.json) in package.json)
- **npm**: Comes with Node.js
- **Git**: For version control

## Quick Start

### Installation

1. **Clone the repository**
```bash
git clone https://github.com/github/docs.git
cd docs
```

2. **Install dependencies**
```bash
npm install
```

3. **Start the development server**
```bash
npm run dev
```
The site will be available at `http://localhost:4000`

### Available Scripts

- `npm run dev` - Start development server with English content only
- `npm run start-all-languages` - Start server with all language versions
- `npm run build` - Build the production version
- `npm test` - Run the test suite
- `npm run lint` - Check code style and formatting
- `npm run prettier` - Format code automatically

Use the table of contents icon <img alt="Table of contents icon" src="./contributing/images/table-of-contents.png" width="25" height="25" /> on the top right corner of this document to navigate to a specific section quickly.

## Contributing
Expand Down
Loading