add contribute guidelines
This commit is contained in:
39
CONTRIBUTING.md
Normal file
39
CONTRIBUTING.md
Normal file
@@ -0,0 +1,39 @@
|
||||
# How to contribute
|
||||
|
||||
Third-party patches are essential for keeping `cnpmjs.org` great.
|
||||
We want to keep it as easy as possible to contribute changes that
|
||||
get things working in your environment. There are a few guidelines that we
|
||||
need contributors to follow so that we can have a chance of keeping on
|
||||
top of things.
|
||||
|
||||
## Getting Started
|
||||
|
||||
* Make sure you have a [GitHub account](https://github.com/signup/free)
|
||||
* Fork the repository on GitHub
|
||||
|
||||
## Making Changes
|
||||
|
||||
* Create a topic branch from where you want to base your work.
|
||||
* This is usually the master branch.
|
||||
* Only target release branches if you are certain your fix must be on that
|
||||
branch.
|
||||
* To quickly create a topic branch based on master.
|
||||
Please avoid working directly on the `master` branch.
|
||||
* Make commits of logical units and including unit tests.
|
||||
* Check for unnecessary whitespace with `git diff --check` before committing.
|
||||
* Make sure your commit messages are in the proper format.
|
||||
* Make sure you have added the necessary tests for your changes.
|
||||
* Run _all_ the tests to assure nothing else was accidentally broken.
|
||||
* Follow [node style guide](https://github.com/felixge/node-style-guide)
|
||||
|
||||
## Submitting Changes
|
||||
|
||||
* Push your changes to a topic branch in your fork of the repository.
|
||||
* Submit a pull request.
|
||||
* Make sure travis-ci test pass.
|
||||
|
||||
# Additional Resources
|
||||
|
||||
* [General GitHub documentation](http://help.github.com/)
|
||||
* [GitHub pull request documentation](http://help.github.com/send-pull-requests/)
|
||||
* [cnpmjs.org](http://cnpmjs.org)
|
||||
20
README.md
20
README.md
@@ -46,12 +46,12 @@ only need to change the registry in config. Even include manual synchronization
|
||||
|
||||

|
||||
|
||||
## Develop
|
||||
## Develop on your local machine
|
||||
|
||||
### Dependencies
|
||||
|
||||
* [node](http://nodejs.org) >=0.11.9
|
||||
* [mysql](http://dev.mysql.com/downloads/), include `mysqld` and `mysql cli`
|
||||
* [mysql](http://dev.mysql.com/downloads/) >= 0.5.0, include `mysqld` and `mysql cli`. I test on `mysql@5.6.16`.
|
||||
|
||||
### Start MySQL
|
||||
|
||||
@@ -63,9 +63,9 @@ $ nohup mysqld &
|
||||
|
||||
```bash
|
||||
# clone from git
|
||||
$ git clone git@github.com:cnpm/cnpmjs.org.git
|
||||
$ git clone https://github.com/cnpm/cnpmjs.org.git
|
||||
|
||||
# install dependencise
|
||||
# install dependencies
|
||||
$ make install
|
||||
|
||||
# test
|
||||
@@ -78,15 +78,15 @@ $ make test-cov
|
||||
$ make autod
|
||||
|
||||
# start server
|
||||
$ node --harmony-generators dispatch.js
|
||||
$ node --harmony dispatch.js
|
||||
```
|
||||
|
||||
## Contribute
|
||||
## How to contribute
|
||||
|
||||
* clone the project
|
||||
* checkout a new branch
|
||||
* add new features or fix bugs in the new branch
|
||||
* make a pull request and we will review it ASAP
|
||||
* Clone the project
|
||||
* Checkout a new branch
|
||||
* Add new features or fix bugs in the new branch
|
||||
* Make a pull request and we will review it ASAP
|
||||
|
||||
Tips: make sure your code is follow the [node-style-guide](https://github.com/felixge/node-style-guide).
|
||||
|
||||
|
||||
Reference in New Issue
Block a user