Skip to content

Commit

Permalink
[Chore #165663486] Create database models
Browse files Browse the repository at this point in the history
  • Loading branch information
rwajon committed Apr 29, 2019
1 parent 165d18f commit e31c531
Show file tree
Hide file tree
Showing 23 changed files with 2,392 additions and 335 deletions.
18 changes: 18 additions & 0 deletions .codeclimate.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
version: "2"
plugins:
rubocop:
enabled: true
eslint:
enabled: true
exclude_patterns:
- "config/"
- "db/"
- "dist/"
- "features/"
- "**/node_modules/"
- "script/"
- "**/spec/"
- "**/test/"
- "**/tests/"
- "**/vendor/"
- "**/*.d.ts"
2 changes: 2 additions & 0 deletions .coveralls.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
service_name: travis-ci
repo_token: 4RaaumwJ4Nj5xob1VFKxIFozVkinsSyVw
21 changes: 15 additions & 6 deletions .env.sample
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
SECRET_KEY= 12345
DATABASE_NAME=database
DB_USER=postgres
DB_PASSWORD=password
DB_PORT=5432
DB_HOST=127.0.0.1
SECRET_KEY = secretkey
DATABASE_DEV_URL = postgres://username:password@localhost:5432/database_name
DATABASE_TEST_URL = postgres://username:password@localhost:5432/database_name

DB_NAME_DEV=authorhavens_dev
DB_HOST_DEV=localhost
DB_USER_DEV=postgres
DB_PASSWORD_DEV=12345
DB_PORT_DEV=5432

DB_NAME_TEST=authorhavens_test
DB_HOST_TEST=localhost
DB_USER_TEST=postgres
DB_PASSWORD_TEST=12345
DB_PORT_TEST=5432
36 changes: 30 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,37 +1,61 @@
# Logs
logs
*.log
.DS_Store

npm-debug.log*
yarn-debug.log*
yarn-error.log*

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage

# nyc test coverage
.nyc_output

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Bower dependency directory (https://bower.io/)
bower_components

# node-waf configuration
.lock-wscript

# Compiled binary addons (http://nodejs.org/api/addons.html)
# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directory
node_modules
# Dependency directories
node_modules/
jspm_packages/

# TypeScript v1 declaration files
typings/

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Optional REPL history
.node_repl_history

.env
# Output of 'npm pack'
*.tgz

# Yarn Integrity file
.yarn-integrity

# dotenv environment variables file
.env

# next.js build output
.next
12 changes: 7 additions & 5 deletions .sequelizerc
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
require("babel-register");
require("@babel/register");

const path= require ('path')
const path = require('path');

module.exports ={
"config": path.resolve('./src/config', 'config.js')
}
module.exports = {
"config": path.resolve('./src/config', 'db-config.js'),
"models-path": path.resolve('./src/models'),
"migrations-path": path.resolve('./src/migrations')
};
19 changes: 19 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
env:
global:
- CC_TEST_REPORTER_ID=d570e2625aaffa20e7828eaddfbec748c525e866b6d413472bc26e188cb2bc6a
language: node_js
node_js:
- "stable"
cache:
directories:
- "node_modules"
before_script:
- curl -L https://codeclimate.com/downloads/test-reporter/test-reporter-latest-linux-amd64 > ./cc-test-reporter
- chmod +x ./cc-test-reporter
- ./cc-test-reporter before-build
script:
- npm run cover
after_script:
- ./cc-test-reporter after-build --exit-code $TRAVIS_TEST_RESULT
after_success:
- npm run coveralls
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[![Build Status](https://travis-ci.org/andela/ninjas-ah-backend.svg?branch=develop)](https://travis-ci.org/andela/ninjas-ah-backend)
[![Build Status](https://travis-ci.org/andela/ninjas-ah-backend.svg?branch=ch-create-db-models-165663486)](https://travis-ci.org/andela/ninjas-ah-backend) [![Coverage Status](https://coveralls.io/repos/github/andela/ninjas-ah-backend/badge.svg?branch=ch-create-db-models-165663486)](https://coveralls.io/github/andela/ninjas-ah-backend?branch=ch-create-db-models-165663486)

Authors Haven - A Social platform for the creative at heart.
=======
Expand Down
Loading

0 comments on commit e31c531

Please sign in to comment.