Skip to content
This repository has been archived by the owner on Feb 8, 2023. It is now read-only.

Commit

Permalink
Merge pull request #61 from redbadger/README
Browse files Browse the repository at this point in the history
Static analysis and documentation
  • Loading branch information
asavin authored Aug 3, 2016
2 parents 4fe9818 + a0f5280 commit 522e942
Show file tree
Hide file tree
Showing 6 changed files with 67 additions and 10 deletions.
17 changes: 17 additions & 0 deletions .codeclimate.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
engines:
duplication:
enabled: true
exclude_paths:
- "**/*spec.js"
config:
languages:
- javascript
eslint:
enabled: true
fixme:
enabled: true
ratings:
paths:
- "**.js"
- "**.jsx"
- "**.module"
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,4 @@ dist

.DS_Store
.env
coverage
File renamed without changes.
50 changes: 42 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,33 +1,63 @@
# Badger Brain
Badger Brain
============

[![CircleCI](https://circleci.com/gh/redbadger/badger-brain.svg?style=shield)](https://circleci.com/gh/redbadger/badger-brain)
[![Test Coverage](https://coveralls.io/repos/github/redbadger/badger-brain/badge.svg?branch=master)](https://coveralls.io/github/redbadger/badger-brain?branch=master)
[![Code Climate](https://codeclimate.com/github/redbadger/badger-brain/badges/gpa.svg)](https://codeclimate.com/github/redbadger/badger-brain)

GraphQL server for all Red Badger related data.

This project is public. No sensitive data should be committed to the repository.
This project is public, so it's even more important that no sensitive data is
committed to the repository.

## Usage

```sh
npm run start # Start the dev server
npm run lint # Run the style linter
npm run test # Run the tests
npm run test-watch # Run the tests and watch for changes
```

## Releasing to live

Few easy steps:

* Create and push a new release tag. You can do it [here](https://github.com/redbadger/badger-brain/releases)
* Generate updated [CHANGELOG](https://github.com/redbadger/badger-brain/blob/master/CHANGELOG.md) file and push it to `master` branch. Use [Github Changelog Generator](https://github.com/skywinder/github-changelog-generator) for this. Don't forget to pull the latest tags from Github before generating updates to the changelog.
* Navigate to AWS console, EB => Badger Brain => App versions. The idea is that we're only promoting app versions that are already deployed to staging env. Find a current version that is on staging right now and deploy it to LIVE.
* Job done
* Create and push a new release tag. You can do it [here][releases].
* Generate updated [CHANGELOG][changelog] file and push it to `master` branch.
Use [Github Changelog Generator][generator] for this. Don't forget to pull
the latest tags from Github before generating updates to the changelog.
* Navigate to AWS console, EB => Badger Brain => App versions. The idea is
that we're only promoting app versions that are already deployed to staging
env. Find a current version that is on staging right now and deploy it to
LIVE.
* Job done.

[releases]: https://github.com/redbadger/badger-brain/releases
[changelog]: https://github.com/redbadger/badger-brain/blob/master/CHANGELOG.md
[generator]: https://github.com/skywinder/github-changelog-generator

## Ideas

This server will provide GraphQL endpoint for fetching and consuming company related data. Much like in the famous [Stevey's Google Platforms Rant](https://gist.github.com/chitchcock/1281611) we should be able to have an interface for communicating company data for whoever decides to consume it.
This server will provide GraphQL endpoint for fetching and consuming company
related data. Much like in the famous [Stevey's Google Platforms Rant][rant]
we should be able to have an interface for communicating company data for
whoever decides to consume it.

[rant]: https://gist.github.com/chitchcock/1281611

List of consumers so far:

* red-badger.com site
* React.London

List of data providers:

* Workable
* Prismic.io

```
.oys:
.oys:
.:dmmmmmmmddhyo+:.
-oddy+:-.`` ``..:/ohmdy+-
-hmmyosyyhhhhyyso+:. -+ymd+`
Expand All @@ -51,3 +81,7 @@ List of data providers:
.smmmmmmm- .mmmmmmmd:
`/osyys. `oyyyso-
```

## Licence

Apache Licence. See LICENCE for details.
4 changes: 3 additions & 1 deletion circle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ dependencies:
test:
override:
- npm run lint
- npm test
- npm run test-with-coverage
post:
- cat ./coverage/lcov.info | ./node_modules/.bin/coveralls

deployment:
staging:
Expand Down
5 changes: 4 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
"serve": "node dist/index.js",
"test": "mocha",
"test-watch": "mocha --watch --reporter min",
"commit": "commit-wizard"
"commit": "commit-wizard",
"test-with-coverage": "istanbul cover ./node_modules/.bin/_mocha"
},
"repository": {
"type": "git",
Expand Down Expand Up @@ -46,10 +47,12 @@
"babel-preset-stage-0": "^6.5.0",
"babel-register": "^6.9.0",
"chai": "^3.5.0",
"coveralls": "^2.11.12",
"eslint": "^2.12.0",
"eslint-config-airbnb": "^9.0.1",
"eslint-plugin-import": "^1.8.1",
"injectr": "^0.5.1",
"istanbul": "^1.0.0-alpha.2",
"mocha": "^3.0.0",
"mocha-trumpet-reporter": "0.0.3",
"nock": "^8.0.0",
Expand Down

0 comments on commit 522e942

Please sign in to comment.