-
Notifications
You must be signed in to change notification settings - Fork 7
Submitting a pull request
You've made changes and you've tested them locally on your computer using 'docker-compose up'. Now you are ready to submit a pull request. Here's how to do it!
If you have been invited to be a member of the GitHub team, then you should be able to push directly to the politicalrev GitHub repo. If not, you can still create a pull request; see below for instructions on forking the repo.
- Commit your changes to your local repo on a new branch using git.
- Push your new branch using git.
- Create a pull request on the GitHub website:
- Go to the Pull Requests tab and click the New Pull Request button.
- The base will be master and the compare will be the name of your new branch.
- Add a title and description that describes the changes in your pull request.
- Click 'Create pull request'.
Travis CI will automatically build your pull request and Github will post to our slack channel letting everyone know a pull request has been submitted. A team lead will review your changes (probably @smona or @innovativedmm).
If there are comments and you need to make additional changes, commit more changes to your branch locally and push them to GitHub. Your new commits will automatically be reflected in your pull request. When the pull request is ready, it will be merged and you should be able to see your changes in the staging environment: https://staging.political-revolution.com/
Thanks for contributing! If you need help or have any questions, ask on one of the dev Slack channels!
If you don't have push privileges, you can still contribute pull requests by forking the repository in GitHub. Forking creates a new copy of the repository under your own account. From a git perspective, the new repo will be unconnected to the politicalrev repo. But GitHub keeps track of forked repositories, and you can create a GitHub pull request across forks.
- Fork the repo by clicking the 'Fork' button at the top right of the GitHub repo page.
- Clone your fork to your local machine.
- If you had already cloned the politicalrev repo, you should update the origin to be your own repo:
'git remote set-url origin git://your.forked.repo' - You should also set the upstream repository:
'git remote add upstream https://github.com/politicalrev/political-revolution.com'
- If you had already cloned the politicalrev repo, you should update the origin to be your own repo:
- When you fetch or pull, you can bring in changes from the upstream repository with:
- 'git fetch upstream'
- Or 'git pull upstream <branch>'
- Make your changes, test, and commit to a new branch using git.
- Push your branch using git (to your forked repo in GitHub).
- Create a pull request on the GitHub website:
- Go to the Pull Requests tab and click the New Pull Request button.
- On the left, the base fork should be politicalrev/political-revolution.com and base should be master.
- The head fork will be <your account>/political-revolution.com and compare will be the name of your new branch.
- Add a title and description that describes the changes in your pull request.
- Click 'Create pull request'.
A team lead will review your changes (probably @smona or @innovativedmm), merge them, and after Travis CI automatically deploys your changes, you'll be able to see it in action in the staging environment: https://staging.political-revolution.com/
Thanks for contributing! If you need help or have any questions, ask on one of the dev Slack channels!