RoboMission is an intelligent web application for learning elementary programming, aiming at creating a flow experience. RoboMission is developed by Adaptive Learning group at Masaryk University.
-
Install Python 3.5, virtualenv, virtualenvwrapper and npm.
-
Configure virtualenv and virtualenvwrapper by adding the following two lines in your
~/.bashrc
:export WORKON_HOME=~/.virtualenvs export VIRTUALENVWRAPPER_PYTHON='/usr/bin/python3' source /usr/local/bin/virtualenvwrapper.sh
The path to the
virtualenvwrapper.sh
might be different depending on the OS and the way you install it.Load the changes:
$ source ~/.bashrc
-
Clone the project repository:
$ git clone https://github.com/adaptive-learning/robomission.git
-
Create virtual environment and bind it with the project directory:
$ cd robomission $ mkvirtualenv robomission && setvirtualenvproject
The name of the virtual environment (robomission) should now appear in front of the prompt.
-
Install dependencies and initialize DB:
$ make install
The
make install
command uses pip to install install backend dependencies, npm for frontend dependencies, and then it sets up the database for development. (See Makefile for details.) You can deactivate the virtual environment by callingdeactivate
. -
Create dummy file with secret keys:
$ cp settings_secret_template.py settings_secret.py
-
Start the virtual environment and jump to the project directory:
$ workon robomission
-
Pull the changes from the repository.
$ git pull
-
Update dependencies and database:
$ make update
-
Create and checkout a git branch for the implemented feature.
$ git checkout -b name_of_the_feature
-
Write unit tests for the implemented feature (and possibly integration tests as well). Check that the tests don't pass.
$ make test
-
Develop the feature. Enjoy it, experience the state of flow :-)
-
To start a server:
$ make server
-
To open python console (with all models automatically imported):
$ make shell
-
To open jupyter notebooek:
$ make notebook
-
To load new tasks (or other domain changes) to DB:
$ make domain
-
If you change the data model, create and apply a migration:
$ ./backend/manage.py makemigrations $ ./backend/manage.py migrate
-
Take a regular breaks and stretch yourself (including your eyes).
-
Test the implemented feature and check the code by a linter:
$ make test $ make lint
-
Commit changes:
$ git add changed_files $ git commit -m "Implement feature X"
-
Merge the feature branch to the master branch:
$ git checkout master $ git merge name_of_the_feature
-
Push changes to the GitHub:
$ git push
-
Deactivate the virtual environment:
$ deactivate
-
Celebrate the developed feature with some physical exercise and healthy snack.
- Use
export SHOW_SQL_QUERIES=True
to log all performed SQL queries. Environment variables can be also passed bymake
, e.g.make server SHOW_SQL_QUERIES=True
.