Skip to content

Commit

Permalink
update module structure to standard
Browse files Browse the repository at this point in the history
  • Loading branch information
cgrayson committed Aug 2, 2017
1 parent 820d593 commit 9a0800a
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 47 deletions.
6 changes: 2 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
language: node_js
node_js:
- 0.10
- 4
- 5
- 6
- node
sudo: false
before_script: cake lint
12 changes: 12 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Change Log
All notable changes to this project will be documented in this file.
This project adheres to [Semantic Versioning](http://semver.org)

## [0.0.8] - 2017-08-03
### Fixed
- changed to handle()-style to suppress parse errors (fixes #10)


## [0.0.2] - 2015-05-28
### Added
- initial implementation
35 changes: 1 addition & 34 deletions Cakefile
Original file line number Diff line number Diff line change
@@ -1,34 +1 @@
{spawn, exec} = require 'child_process'
fs = require 'fs'
log = console.log

task 'build', ->
coffeePath = './node_modules/coffee-script/bin/coffee'
if fs.existsSync(coffeePath)
run "rm -rf lib; #{coffeePath} -o lib -c src"
else
console.log('> skipping build because coffee-script is not installed')

task 'test', ->
run 'NODE_ENV=test TZ=GMT ./node_modules/.bin/mocha spec/* --compilers coffee:coffee-script/register --reporter spec --colors'

task 'lint', ->
run 'curl --silent http://leadconduit-build.s3.amazonaws.com/coffeelint.json > coffeelint.json && ./node_modules/.bin/coffeelint -f coffeelint.json src/*'

run = (args...) ->
for a in args
switch typeof a
when 'string' then command = a
when 'object'
if a instanceof Array then params = a
else options = a
when 'function' then callback = a

command += ' ' + params.join ' ' if params?
cmd = spawn '/bin/sh', ['-c', command], options
cmd.stdout.on 'data', (data) -> process.stdout.write data
cmd.stderr.on 'data', (data) -> process.stderr.write data
process.on 'SIGHUP', ->
cmd.kill()
cmd.on 'exit', (code) ->
process.exit(code)
require('leadconduit-cakefile')(task)
11 changes: 2 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
{
"name": "leadconduit-pixeltracker",
"description": "LeadConduit pixel tracker",
"author": "Lynda Wellhausen <[email protected]>",
"version": "0.0.7",
"main": "index.js",
"licenses": [
{
"type": "Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International",
"url": "http://creativecommons.org/licenses/by-nc-nd/4.0/legalcode"
}
],
"license": "CC-BY-NC-ND-4.0",
"repository": {
"type": "git",
"url": "https://github.com/activeprospect/leadconduit-integration-pixeltracker"
Expand All @@ -28,8 +22,7 @@
"devDependencies": {
"chai": ">= 1.9.0",
"coffee-script": ">= 1.7.0",
"coffeelint": "^1.10.0",
"leadconduit-fields": "^3.0.0",
"leadconduit-cakefile": "^0.3.1",
"mocha": ">= 1.17.0",
"nock": "^9.0.13"
}
Expand Down

0 comments on commit 9a0800a

Please sign in to comment.