App skeleton. TODO : divide code into different scripts