Git Workflow - Sorcery/sorcery GitHub Wiki
Preparing local instance
- Fork Sorcery on Github
- Clone your forked copy onto your working machine
- Open terminal and
cd
into where you would like the repository saved. - Run the clone command, example:
git clone https://github.com/<your_user_name>/sorcery.git
- With the same terminal,
cd
into your freshly made repository using:cd ./sorcery
- Add upstream to remotes
git remote add upstream https://github.com/Sorcery/sorcery.git
- Run
bundle install
- To ensure everything is ready, run
bundle exec rspec spec
, all tests should pass.
Merging your contributions
- Make your changes, adding additional specs if you are adding functionality.
- Run
bundle exec rspec spec
to ensure your changes didn't break other functionality. git commit
with a relevant message- Pull down any updates
git pull --rebase upstream master
- If there are any conflicts, resolve them via text editor then run:
*
git add -A
thengit rebase --continue
git push --force-with-lease
- (WARNING: This will delete any history on your github fork and overwrite it with your local copy. This is necessary however if history was rewritten due to changes to the main repository.)
- Submit a pull-request via github.
This page is a work in progress; if you have any suggestions or see any mistakes, please update the page as needed!