Divvying up expenses between friends and peers can be a disaster. Remember that time you went on a trip and one person rented the car and another paid for dinners and a third bought the gas and the beer and then you had to even-up while accounting for tips? Or that time rent was due but someone had purchased all of the groceries and utilities for the month? Enter Divvy.
Divvy allows users to enter expenses as they are incurred, and calculates the best way to settle the bill. No more painful math and messy payments to different people, Divvy simplifies everything down to one payment per person.
- Product Owner: Hannah Henderson
- Scrum Master: James Ramadan
- Development Team Members: Dennis Ting, Wayne Adams
- Node - v6.3.0
- Sequelize - ORM for defining app data relationships and managing queries.
- Express - Server with convenient routing and large collection of middleware packages to handle requests.
- Angular - MV* framework to build readable, maintainable, and testable client interface to our app. The app may be reviewed by another group as a legacy project.
- Gulp - Task runner to automate and simplify development, build, and deployment processes.
- Node 6.3.0
- NPM 3.10.3
- Run
npm install
from the command line. - Run
bower install
from the command line.
- Sign up to be a Facebook developer.
- Click the "Create a New App" on your apps page.
- Choose a "Website" app and give it a name.
- Add a contact email and a category when prompted.
- Complete the captcha and wait for the app to be created.
- Scroll down to the "Tell us about your website" portion of the next page, enter:
http://localhost:3000/
- Click "Next" and scroll back to the top of the page. Click on the "Skip Quick Start" button.
- Click the "+ Add Product" button on the left side of the dashboard.
- Click the "Get Started" button next to "Facebook Login".
- For "Valid OAuth redirect URIs", enter:
http://localhost:3000/auth/facebook/callback
- Click "Save Changes" on the bottom right.
- Go back to the app dashboard by clicking the "Dashboard" menu item on the top left.
- Make a copy of
./server/config/.env.sample.js
as./server/config/.env.js
. Notice that the.env.js
file is a JavaScript file. The value for each property of the exported object in this file should be a string. Make sure there are single quotes around the pasted in values. - Copy the "App ID" and replace
FACEBOOK_ID
's value with the copied value. - Click the "Show" button for "App Secret". Enter your Facebook password to display the value. Copy the shown value and into the
.env.js
file as theFACEBOOK_SECRET
. - With the dev server running, navigating to
http://localhost:3000/auth/facebook
redirects the browser to Facebook and ask for app authorization. Once authorized, the browser redirects tohttp://localhost:3000/auth/facebook/callback
with acode
query param (logged on the server). The browser then redirects to the application root.
Assumes user has a developer account with Heroku. Accounts are free to create for up to five projects.
- Run
gulp build
from the root directory. - Change directory to the "dist" folder.
- Create a deployment remote using
Heroku Create
. - Use the Heroku dashboard to view new remote.
Can change the app name at this step.
Reset remote path name using
git remote set-url heroku https://git.heroku/APPNAME.git
- Select current project and navigate to "settings". Click on "Reveal config vars".
- Populate keys for NODE_ENV, DOMAIN, SESSION_SECRET, FACEBOOK_ID, and FACEBOOK_SECRET using the information from the
.env.js
file. a. Set NODE_ENV equal to "deployment". b. Set DOMAIN equal to the website link generated by Heroku. Ensure there is no trailing "/". Website name will be of formathttps://git.heroku.com/APPNAME.git
. c. Set SESSION_SECRET equal to a secure random string. http://randomkeygen.com/ d. Set FACEBOOK_ID to developer facebook ID. e. Set FACEBOOK_SECRET to developer Facebook secret. - Enter
heroku ps:scale web=1
into the command line to ensure at least one instance is running. - Navigate to app within Facebook's developer tools.
a. On the navigation bar (left) select "Facebook Login". Scroll down to client OAuth Settings to "Valid OAuth redirect URIs" and enter in the app DOMAIN (used above) followed by "auth/facebook/callback", likely of format
https://git.heroku.com/APPNAME.git/auth/facebook/callback
. Save changes. b. Under App Review (on left navigation bar), make the app public by selecting "Yes" at the top.
View the project roadmap here.
See CONTRIBUTING.md for contribution guidelines.