-
Notifications
You must be signed in to change notification settings - Fork 0
Backend: Keeping your local environment up to date
Tim K edited this page Sep 3, 2018
·
6 revisions
It is important to keep your local development environment up-to-date with online Fizzyo-backend
repository, namely the dev
branch. To sync your local dev
you can do the following:
$ git checkout dev # Switch to local `dev` branch
$ git fetch -a # Fetch all updates from remote repository
$ git status # See if you're missing any commits locally
$ git pull origin dev # Pull remote changes
There are three possible scenarios here:
- Pull is successful. Everything is probably okay, but you should run tests just in case to make sure nothing broke:
npm run test-all
. - Pull went through but generated merge conflicts. This means you will have to manually resolve merge conflicts. Check out this guide from GitHub. Merge conflicts can be tricky to resolve, so make sure to Google around for advice. If needed, contact someone from the Fizzyo core development team.
- Pull was rejected because you have unstaged changes. You can try using
git stash
, but make sure you understand what it does before using it.
Given other developers did not mess up, this should be as easy as switching to Fizzyo-backend
folder and running automatic migration script:
$ cd Fizzyo-backend/
$ npm run migrate-db dev
This operation will do nothing if no new migrations are found, so you can run it preemptively whenever you pull in new code.
If any of the documentation you see on this page is inaccurate, please create an issue or report it to Tim Kuzhagaliyev at tim.kuzhagaliyev.15 (at) ucl.ac.uk
.
- Meta:
- Tutorials:
- Notes:
- Coming soon.