Dev Setup: Windows
David Liu edited this page 2016-09-10 18:08:37 -07:00

Tools

You will need to install the following:

Set Up

First open up cmd.exe/Powershell/Git Bash/any terminal.

You'll want to fork the repo on Github, then clone it to your machine.

git clone https://github.com/$GITHUB_USERNAME/codecombat.git
cd codecombat
git remote add -f upstream https://github.com/codecombat/codecombat.git

You'll then want to install the dependencies and build the asset files.

npm install

Start MongoDB if you haven't, then download the database dump at http://analytics.codecombat.com:8080/dump.tar.gz, extract the contents (7-Zip is a good option), then

mongorestore --drop path/to/dump --db coco

(If it says that there are no reachable servers but there is a mongod process running try adding --host=127.0.0.1 to the end of the command.)

Running

Either run npm run dev (live coding) or npm start (just previewing) to start the server.

Visit http://localhost:3000 to see your CodeCombat setup in action.