Comparing version 1.0.0 to 1.0.1
@@ -16,3 +16,3 @@ var cp = require('child_process') | ||
files = files.filter(function (file) { | ||
return !/\/node_modules\/|\.min.js$/.test(file) | ||
return !/\/node_modules\/|\/.git\/|\.min.js$/.test(file) | ||
}) | ||
@@ -19,0 +19,0 @@ |
{ | ||
"name": "standard", | ||
"description": "Enforce code style standards", | ||
"version": "1.0.0", | ||
"description": "JavaScript Standard Style", | ||
"version": "1.0.1", | ||
"author": { | ||
@@ -6,0 +6,0 @@ "name": "Feross Aboukhadijeh", |
@@ -10,4 +10,23 @@ # standard [![travis][travis-image]][travis-url] [![npm][npm-image]][npm-url] [![downloads][downloads-image]][downloads-url] | ||
### Enforce code style standards | ||
### JavaScript Standard Style | ||
## Rules | ||
- No semicolons ([it's fine][1] – *[really][2]!*) | ||
- Indentation is 2 spaces | ||
- Strings use single quotes | ||
- Unix-style line breaks (LF) | ||
- Spaces after keywords: | ||
- `if (condition) { ... }` | ||
- Spaces before/after function definitions:, like this: | ||
- `function name (arg1, arg2) { ... }` | ||
- Always name the context variable `self`: | ||
- `var self = this` | ||
[1]: http://blog.izs.me/post/2353458699/an-open-letter-to-javascript-leaders-regarding | ||
[2]: http://inimino.org/~inimino/blog/javascript_semicolons | ||
To get a better idea, take a look at | ||
[a sample file](https://github.com/feross/bittorrent-dht/blob/master/client.js). | ||
## install | ||
@@ -33,3 +52,3 @@ | ||
```bash | ||
``` | ||
$ standard | ||
@@ -58,3 +77,3 @@ Error: Code style check failed: | ||
```bash | ||
``` | ||
$ npm test | ||
@@ -61,0 +80,0 @@ Error: Code style check failed: |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
9793
86