The following steps will create a development environment. These steps only need to be done the first time you contribute.
1. Fork this repository on GitHub and clone your fork to your development environment
git clone [email protected]:YOUR-GITHUB-USERNAME/yii2-db-rbac.git
Change to the directory where you cloned. Then enter the following command:
git remote add upstream git://github.com/developeruz/yii2-db-rbac.git
Having prepared your develop environment as explained above you can now start working on the feature or bugfix.
git fetch upstream
You should start at this point for every new contribution to make sure you are working on the latest code.
Each separate bug fix or change should go in its own branch. Branch names should be descriptive. For example:
git checkout upstream/master
git checkout -b name-of-your-branch-goes-here
Make sure it works :)
Edit the CHANGELOG file to include your change. The line in the change log should look like one of the following:
Bug: a description of the bug fix (Your Name)
Enh: a description of the enhancement (Your Name)
add the files/changes you want to commit to the staging area with
git add path/to/my/file.php
Commit your changes with a descriptive commit message.
git commit -m "A brief description of this change"
git pull upstream master
This ensures you have the latest code in your branch before you open your pull request. If there are any merge conflicts, you should fix them now and commit the changes again. This ensures that it's easy to merge your changes with one click.
git push -u origin name-of-your-branch-goes-here
8. Open a pull request against upstream.
Go to your repository on GitHub and click "Pull Request", choose your branch on the right and enter some more details in the comment box.