Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Mar 9, 2021. It is now read-only.

Docs update #105

Merged
merged 10 commits into from
Nov 16, 2017
Merged
Changes from 5 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
164 changes: 146 additions & 18 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,29 +1,157 @@
# Contribution guidlines
# How to Contribute

We welcome pull requests from hackerspace members (our students) and seasoned JavaScript developers alike! Follow these steps to contribute:
Coderplex web application comprises of two repositories :

1. Find an issue that needs assistance by searching for the [Help Wanted](https://github.com/coderplex/coderplex/labels/help-wanted) tag.
- [Coderplex](https://github.com/coderplex/coderplex) * : Frontend of the application
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check this line once we have * by mistake I think


1. Let us know you are working on it by posting a comment on the issue.
- [Coderplex-Backend](https://github.com/coderplex/coderplex-backend) : Backend of the application

1. Follow the [Contribution Guidelines](#contribution-guidelines) to start working on the issue.
Both of them are under very active development. This document provides non exhaustive guidelines for contributing to this repository.

Remember to feel free to ask for help in our [Discord](https://discordapp.com/invite/dVnQ2Gf) rooms.
## Code of Conduct
Coderplex has adopted [Contributor Covenant](https://github.com/coderplex/coderplex/blob/docs-update/CODE_OF_CONDUCT.md) that we expect project participants to adhere to.

Working on your first Pull Request? You can learn how from this *free* series [How to Contribute to an Open Source Project on GitHub](https://egghead.io/series/how-to-contribute-to-an-open-source-project-on-github)
## Open Development
All work related to the application takes place on Github itself. We use [Issues](https://github.com/coderplex/coderplex/issues) to track bugs, discuss ideas and to engage open source contributors. [Projects](https://github.com/coderplex/coderplex/projects) are used to keep track of everything and is our project management tool. We maintain [Wiki](https://github.com/coderplex/coderplex/wiki) for structuring our long term thoughts. Both core team members and contributors sends a pull request which goes through the same review process. Whole process is as transparent as it can be and we strive to keep it that way.

## Running this project locally
## Development Workflow

1. Make sure you have [NodeJS](https://nodejs.org/) and [Yarn](https://yarnpkg.com/en/docs/install) installed.
> Make sure you install node version 8 or above and check node version by running `node -v`
1. Then clone this repo
We welcome pull requests from beginners and seasoned javaScript developers alike!

### Work on Issues
1. Find an issue that needs assistance by searching for the [open issues](https://github.com/coderplex/coderplex/labels/help-wanted).
2. If you decide to fix an issue, please be sure to check the comment thread in case somebody is already working on a fix. If nobody is working on it at the moment, please leave a comment stating that you intend to work on it so other people don’t accidentally duplicate your effort.
3. If somebody claims an issue but doesn’t follow up for more than a weeks, it’s fine to take over it but you should still leave a comment.


### Proposing a Change
1. Open a new issue if you would like report a bug or suggest improvements.
2. Please wait for core team members to comment on the thread. This lets us reach an agreement on your proposal before you put significant effort into it.

### Prerequisites
1. [NodeJS](https://nodejs.org/)
<br/>
Minimum version v8.0.0+
```bash
git clone https://github.com/coderplex/coderplex.git
To check node version
$ node -v
```
1. `cd coderplex`
1. `npm install`
1. `npm run dev` to start local development server
1. App opens at `localhost:3000`
Any lower version than mentioned above may results in this [error](https://github.com/coderplex/coderplex/issues/100).
> If you face problem updating your node then you might need a Node version manager tool. [Follow here]()

2. [Yarn](https://yarnpkg.com)
<br/>
Minimum version v1.2.0+
<br/>
Installing instructions are at [official docs](https://yarnpkg.com/en/docs/install#windows-tab).
Use yarn over npm
> Our team's official policy (for now) is: We only use [Yarn](https://yarnpkg.com/en/docs/install) as our official Node package manager, and so we request you to use Yarn instead of npm and commit `yarn.lock` file.

3. [Git](https://git-scm.com/download/linux)
<br/>
Familiarity with git is mandatory.

### Running
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this should be labeled as

Running Locally

And I feel it should go under Sending a Pull Request section


1. Clone repository
```bash
$ git clone https://github.com/coderplex/coderplex.git
```
2. Move to the repository root folder
```bash
$ cd coderplex
```
3. Install dependencies
```bash
$ yarn
```
4. Start the development server
```bash
$ yarn dev
```
App now opens at `localhost:3000` in your default browser.
> You may get this [error]() if any other app is already running the above port.

### Sending a Pull Request

*Working on your first Pull Request? You can learn how from this *free* series [How to Contribute to an Open Source Project on GitHub](https://egghead.io/series/how-to-contribute-to-an-open-source-project-on-github)*

#### Before submitting:
1. Fork the [repository](https://github.com/coderplex/coderplex).
2. From your fork, create a [branch](https://help.github.com/articles/creating-and-deleting-branches-within-your-repository/) and name it. eg. `typo-in-readme`
3. If you’ve fixed a bug or added code that should be tested, add tests!
4. Ensure that all test pass
```bash
$ yarn test
```
5. Run code formatters
```bash
$ yarn lint
```
6. Add and commit your code. Please give meaning full commit messages.
7. Pull latest code from [upstream repository's ](https://help.github.com/articles/merging-an-upstream-repository-into-your-fork/)`master`, if in case anything new were merged while you were working on your fork.
Copy link
Contributor

@vinaypuppal vinaypuppal Nov 16, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull latest code from upstream repository's master,

Here its develop I think?

8. Push the code to your fork.
9. Raise the pull request from your created branch to `master` branch of coderplex.
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shoud we change this to develop. and explain a little about out branching system?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ping!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change what to develop?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes we will be changing default branch as devlop (I made typo while creating this will modify soon to develop). So update master to develop in guide and mention why we are doing so.

10. Take some time to give a brief description of the work you have done.

#### After submitting
1. Wait for all checks to pass in below section.
2. Your changes are deployed with a unique link `https://deploy-preview-xx--coderplex.netlify.com`. <br/>
*`- xx` is your pull request number.*
3. The core team will review your pull request and either merge it, request changes to it, or close it with an explanation.

##### Received a review request
- Work on the requested changes
- Push the changes as you did earlier, the pull request will automatically catch those and update itself.

### How to get in touch
- Coderplex [Discord Channel](https://discord.gg/dVnQ2Gf)
- Tweet core team members :
- Vinay Puppal [@VinayPuppal](https://twitter.com/vinaypuppal)
- Md-ZubairAhmed [@Md_ZubairAhmed](https://twitter.com/Md_ZubairAhmed)
- P Bhanu Teja [@pbteja1998](https://twitter.com/pbteja1998)

## Appendix
##### 1. Node Version Manager

###### [nvm](https://github.com/creationix/nvm) for Linux & OSX
```bash
Installation
$ curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.33.6/install.sh | bash

Install latest node lts
$ nvm install --lts

Use installed version
$ nvm use --lts

Run the app in the same terminal session
```
*Make sure you have [curl](https://curl.haxx.se/) installed*

###### [nvm-windows](https://github.com/coreybutler/nvm-windows) for Windows
It comes with an [installer](https://github.com/coreybutler/nvm-windows#installation--upgrades).

```bash
Install particular version
$ nvm install 8.9.1

Use installed version
$ nvm use 8.9.1
```
Still facing problem this [article](https://medium.com/appseed-io/how-to-run-multiple-versions-of-node-js-with-nvm-for-windows-ffbe5c7a2b47) from [@skounis ](https://twitter.com/skounis) explain in details.

**Note:**
> So our team's official policy (for now) is: We only use [Yarn](https://yarnpkg.com/en/docs/install) as our official Node package manager, and so we request you to use Yarn instead of npm and commit yarn.lock file.
##### 2. Local host occupied
```bash
Error: listen EADDRINUSE :::3000
at Object._errnoException (util.js:1024:11)
at _exceptionWithHostPort (util.js:1046:20)
at Server.setupListenHandle [as _listen2] (net.js:1351:14)
at listenInCluster (net.js:1392:12)
at Server.listen (net.js:1476:7)
at app.prepare.then (/home/m-zubairahmed/github/official/coderplex-frontend/server.js:26:6)
at <anonymous>
at process._tickCallback (internal/process/next_tick.js:188:7)
error Command failed with exit code 1.
```
If you get this error while running `yarn dev` then probably another app is occupying `localhost:3000`. You may want to close that and run the command again.