Skip to content

vincentchov/HampHack

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

71 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BreadCrumbs

Environment Setup

First, make sure to install mysql and libmysqlclient-dev.

$ sudo apt-get install mysql-server
$ sudo apt-get install libmysqlclient-dev

To get the development environment setup, make sure the python3-dev, virtualenv, and pip are installed. Start by running

$ virtualenv -p python3
$ source env/bin/activate
$ pip install -r requirements.txt
$ export FLASK_APP=run.py

To run the application:

$ flask run

Database Configuration

Log into mysql as a root user:

$ mysql -u root -p

Create a new user (this will be you) and password. Then create the database:

mysql> CREATE USER 'mynewuser'@'localhost' IDENTIFIED BY 'goodPassword';
mysql> GRANT ALL PRIVILEGES ON * . * TO 'mynewuser'@'localhost';
mysql> CREATE DATABASE breadcrumbs;

To configure the database, make a copy of the example database config file:

$ cp db_config.py.example db_config.py

and change your username and password in db_config.py.

Now run the database migrations:

$ flask db upgrade

If you make any changes to the models, you can create new migrations by running

$ flask db migrate

About

A repo for our HampHack Spring 2017 hackathon project!

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published