A Flask and AngularJS web application
-
Run
./install.sh
while in the root folder to set up Flask environment -
MAIL_PASSWORD={mail-password} ADMIN_USER={admin-username} ADMIN_PASS={admin-pass} [email protected]/bin/python db_create.py
to create database. if you encounter any error, delete app.db in root folder and run again ** Note: it might lead to data loss. -
Install [Node.js][] (>=0.12 < 4, npm >=2 <3)
-
Run
npm install -g gulp
to install gulp globally -
Run
npm install -g bower
to install bower globally -
Run
npm install -g standard
to install standard globally (used for running standardjs style checks) -
cd angular_app
to run -
npm install
to install node packages which will also runbower install
, if bower packages didn't install, run it bybower i
-
To run unit test
gulp test
, once test comepleted, opencoverage/lcov/lcov-report/index.html
to see test coverage report. -
Run
gulp build
to build(inject dependencies, minifyjs
,css
,html
) fromsrc
folder and copy the source code toapp/static
folder -
Run
npm test
to run AngularJS test -
while in root folder run
flask/bin/nosetests
to run flask server side unit test
- cd angular_app and run
grunt build
to generate minified version of the client side and place inapp/static
folder - cd to root folder and run the following commands.
- MAIL_SENDER= MAIL_PASSWORD= ADMIN_USER= ADMIN_PASS= ADMIN_EMAIL= flask/bin/python run.py
- open browser and navigate to
http://localhost:5000
to serve directly from server side or cd angular_app
and rungulp serve
it will automatically open a chrome browser (this is only for development purpose)
Released under the [ISC][license].