Skip to content

Commit

Permalink
[UPDATE] dotfiles, README.md, dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
Planeshifter committed Mar 20, 2015
1 parent 7a9f748 commit ef1751b
Show file tree
Hide file tree
Showing 8 changed files with 62 additions and 22 deletions.
1 change: 1 addition & 0 deletions .gitattributes
@@ -0,0 +1 @@
* text=auto
14 changes: 14 additions & 0 deletions .jshintignore
@@ -0,0 +1,14 @@

# Directories #
###############
build/
reports/
dist/

# Node.js #
###########
/node_modules/

# Git #
#######
.git*
1 change: 1 addition & 0 deletions .npmignore
Expand Up @@ -47,5 +47,6 @@ Desktop.ini
# Utilities #
#############
.jshintrc
.jshintignore
.travis.yml
.editorconfig
11 changes: 9 additions & 2 deletions .travis.yml
@@ -1,5 +1,12 @@
language: node_js
node_js:
- "0.10"
- '0.12'
- '0.11'
- '0.10'
- '0.8'
- 'iojs'
before_install:
- npm update -g npm
after_script:
- npm run coveralls
- npm run coveralls

25 changes: 19 additions & 6 deletions Makefile
Expand Up @@ -8,29 +8,31 @@ NODE_ENV ?= test

# NOTES #

NOTES ?= 'TODO|FIXME'
NOTES ?= 'TODO|FIXME|WARNING|HACK|NOTE'


# MOCHA #

# Specify the test framework bin locations:
MOCHA ?= ./node_modules/.bin/mocha
_MOCHA ?= ./node_modules/.bin/_mocha

# Specify the mocha reporter:
MOCHA_REPORTER ?= spec


# ISTANBUL #

# Istanbul configuration:
ISTANBUL ?= ./node_modules/.bin/istanbul
ISTANBUL_OUT ?= ./reports/coverage
ISTANBUL_REPORT ?= lcov
ISTANBUL_LCOV_INFO_PATH ?= $(ISTANBUL_OUT)/lcov.info
ISTANBUL_HTML_REPORT_PATH ?= $(ISTANBUL_OUT)/lcov-report/index.html


# JSHINT #

JSHINT ?= ./node_modules/.bin/jshint
JSHINT_REPORTER ?= ./node_modules/jshint-stylish/stylish.js



# FILES #

Expand Down Expand Up @@ -100,6 +102,18 @@ view-istanbul-report:



# LINT #

.PHONY: lint lint-jshint

lint: lint-jshint

lint-jshint: node_modules
$(JSHINT) \
--reporter $(JSHINT_REPORTER) \
./


# NODE #

# Installing node_modules:
Expand All @@ -117,7 +131,6 @@ clean-node:


# CLEAN #

.PHONY: clean

clean:
Expand Down
12 changes: 5 additions & 7 deletions README.md
@@ -1,4 +1,4 @@
logspace
Logspace
===
[![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Coverage Status][coveralls-image]][coveralls-url] [![Dependencies][dependencies-image]][dependencies-url]

Expand All @@ -16,8 +16,6 @@ For use in the browser, use [browserify](https://github.com/substack/node-browse

## Usage

To use the module,

``` javascript
var logspace = require( 'compute-logspace' );
```
Expand Down Expand Up @@ -69,7 +67,7 @@ $ node ./examples/index.js

### Unit

Unit tests use the [Mocha](http://visionmedia.github.io/mocha) test framework with [Chai](http://chaijs.com) assertions. To run the tests, execute the following command in the top-level application directory:
Unit tests use the [Mocha](http://mochajs.org) test framework with [Chai](http://chaijs.com) assertions. To run the tests, execute the following command in the top-level application directory:

``` bash
$ make test
Expand All @@ -93,15 +91,15 @@ $ make view-cov
```


---
## License

[MIT license](http://opensource.org/licenses/MIT).
[MIT license](http://opensource.org/licenses/MIT).


---
## Copyright

Copyright © 2014. Athan Reines.
Copyright © 2014-2015. Athan Reines.


[npm-image]: http://img.shields.io/npm/v/compute-logspace.svg
Expand Down
8 changes: 4 additions & 4 deletions lib/index.js
Expand Up @@ -18,7 +18,7 @@
* LICENSE:
* MIT
*
* Copyright (c) 2014. Athan Reines.
* Copyright (c) 2014-2015. Athan Reines.
*
*
* AUTHOR:
Expand Down Expand Up @@ -51,16 +51,16 @@ function logspace( a, b, len ) {
d;

if ( typeof a !== 'number' || a !== a ) {
throw new TypeError( 'logspace()::invalid input argument. Exponent of start value must be numeric.' );
throw new TypeError( 'logspace()::invalid input argument. Exponent of start value must be numeric. Value: `' + a + '`.' );
}
if ( typeof b !== 'number' || b !== b ) {
throw new TypeError( 'logspace()::invalid input argument. Exponent of stop value must be numeric.' );
throw new TypeError( 'logspace()::invalid input argument. Exponent of stop value must be numeric. Value: `' + b + '`.' );
}
if ( arguments.length < 3 ) {
len = 10;
} else {
if ( !isInteger( len ) || len < 0 ) {
throw new TypeError( 'logspace()::invalid input argument. Length must be a positive integer.' );
throw new TypeError( 'logspace()::invalid input argument. Length must be a positive integer. Value: `' + len + '`.' );
}
if ( len === 0 ) {
return [];
Expand Down
12 changes: 9 additions & 3 deletions package.json
Expand Up @@ -10,6 +10,10 @@
{
"name": "Athan Reines",
"email": "kgryte@gmail.com"
},
{
"name": "Philipp Burckhardt",
"email": "pburckhardt@outlook.com"
}
],
"scripts": {
Expand Down Expand Up @@ -42,10 +46,12 @@
"validate.io-integer": "^1.0.1"
},
"devDependencies": {
"chai": "1.x.x",
"mocha": "1.x.x",
"chai": "2.x.x",
"coveralls": "^2.11.1",
"istanbul": "^0.3.0"
"istanbul": "^0.3.0",
"jshint": "^2.6.3",
"jshint-stylish": "^1.0.1",
"mocha": "2.x.x"
},
"licenses": [
{
Expand Down

0 comments on commit ef1751b

Please sign in to comment.