Skip to content

Dev: How to contribute code to NFTsim

stuart-knock edited this page Aug 9, 2018 · 2 revisions

How to contribute code to NFTsim

We adopt the fork & pull model. The basic workflow is described below.

  1. Fork NFTsim.
  2. Clone your fork locally.
  3. Set an upstream repo to pull changes from the main nftsim repo if you want to keep your fork up to date with the base repository. Bear in mind that the default remote branch in nftsim is called master. Once the upstream repo is set up you can do:
    git pull upstream master
    
    every time you want to fetch the latest changes from the main repo. And NEVER EVER COMMIT TO THE master BRANCH if you want to contribute some code.
  4. New features should be developed in different branches. So, with a clean, fresh up-to-date branch master of upstream you can start by creating a new branch where you'll modify the code:
    git branch new_feature
    
  5. Make some changes in your new branch, stage the files and commit them as usual.
  6. Push the new branch to your remote repo. Make sure you are in the right branch.
    git push origin new_feature
    
  7. Send a pull-request.