Skip to content

Commit

Permalink
Initial project commit
Browse files Browse the repository at this point in the history
  • Loading branch information
cflynn07 committed Jan 24, 2016
0 parents commit 2ec6532
Show file tree
Hide file tree
Showing 10 changed files with 114 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .babelrc
@@ -0,0 +1,3 @@
{
"presets": ["es2015"]
}
8 changes: 8 additions & 0 deletions .gitignore
@@ -0,0 +1,8 @@
*.log
.DS_Store
.idea/
coverage/
lib/
node_modules/
whitelist-all.txt
whitelist-test.txt
8 changes: 8 additions & 0 deletions .npmignore
@@ -0,0 +1,8 @@
*.log
*_test.js
.DS_Store
coverage/
src/
test-mocks/
whitelist-all.txt
whitelist-test.txt
21 changes: 21 additions & 0 deletions LICENSE.md
@@ -0,0 +1,21 @@
The MIT License (MIT)

Copyright (c) 2015 Casey Flynn

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
15 changes: 15 additions & 0 deletions README.md
@@ -0,0 +1,15 @@
simple-producer-consumer
========================

A project to demonstrate bi-directional asynchronous network communication between independent
Node.js processes.

Usage
-----

Tests
-----

License
-------
MIT
49 changes: 49 additions & 0 deletions package.json
@@ -0,0 +1,49 @@
{
"name": "simple-producer-consumer",
"version": "1.0.0",
"description": "A simple demo of producer and consumer node.js services",
"main": "consumer.js",
"scripts": {
"build": "babel ./src -d ./lib",
"lint": "npm run whitelist-generate-all; standard -v `cat ./whitelist-all.txt`; npm run whitelist-remove",
"prepublish": "npm run build",
"test": "npm run lint; npm run whitelist-generate-test; istanbul cover _mocha `cat ./whitelist-test.txt`; npm run whitelist-remove; istanbul check-coverage --statement 100 --branch 100 --function 100 --line 100",
"test-html-cov": "npm run whitelist-generate-test; istanbul cover _mocha `cat ./whitelist-test.txt`; npm run whitelist-remove; open -a 'Google Chrome' coverage/lcov-report/index.html",
"whitelist-generate-all": "find ./src -name '*.js' > ./whitelist-all.txt",
"whitelist-generate-test": "find ./src -name '*_test.js' > ./whitelist-test.txt",
"whitelist-remove": "rm ./whitelist*.txt"
},
"repository": {
"type": "git",
"url": "git+https://github.com/cflynn07/simple-producer-consumer.git"
},
"author": "Casey Flynn <cflynn.us@gmail.com>",
"license": "MIT",
"bugs": {
"url": "https://github.com/cflynn07/simple-producer-consumer/issues"
},
"homepage": "https://github.com/cflynn07/simple-producer-consumer#readme",
"standard": {
"parser": "babel-eslint",
"globals": [
"after",
"afterEach",
"before",
"beforeEach",
"describe",
"it"
]
},
"dependencies": {
"socket.io": "^1.4.4"
},
"devDependencies": {
"babel-cli": "^6.4.5",
"babel-eslint": "^4.1.6",
"babel-preset-es2015": "^6.3.13",
"istanbul": "^0.4.2",
"mocha": "^2.3.4",
"standard": "^5.4.1",
"unit.js": "^2.0.0"
}
}
10 changes: 10 additions & 0 deletions src/consumer.js
@@ -0,0 +1,10 @@
/**
* Processes requests with specified arithmetic operations. Computes the result of each operation
* and responds
* @module src/consumer
*/
'use strict'

import * as io from 'socket.io'

console.log('io', io)
Empty file added src/consumer_test.js
Empty file.
Empty file added src/producer.js
Empty file.
Empty file added src/producer_test.js
Empty file.

0 comments on commit 2ec6532

Please sign in to comment.