remark-lint
Advanced tools
Comparing version 2.1.0 to 2.2.0
@@ -5,2 +5,7 @@ <!--remark setext--> | ||
2.2.0 / 2016-01-13 | ||
================== | ||
* Add support for global externals when running globally ([589b4d7](https://github.com/wooorm/remark-lint/commit/589b4d7)) | ||
2.1.0 / 2016-01-09 | ||
@@ -7,0 +12,0 @@ ================== |
@@ -24,2 +24,3 @@ /** | ||
var filter = require('./filter'); | ||
var npmPrefix = require('npm-prefix')(); | ||
@@ -34,4 +35,9 @@ /* | ||
var resolve = path && path.resolve; | ||
var isWindows; | ||
var isGlobal; | ||
var globals; | ||
var cwd; | ||
var MODULES = 'node_modules'; | ||
/* istanbul ignore else */ | ||
@@ -41,2 +47,9 @@ if (typeof global !== 'undefined') { | ||
cwd = global.process.cwd(); | ||
/* Detect whether we’re running as a globally installed package. */ | ||
isWindows = global.process.platform === 'win32'; | ||
isGlobal = global.process.argv[1].indexOf(npmPrefix) === 0; | ||
/* istanbul ignore next */ | ||
globals = resolve(npmPrefix, isWindows ? '' : 'lib', MODULES); | ||
} | ||
@@ -123,2 +136,10 @@ | ||
* | ||
* When using a globally installed executable, the | ||
* following are also included: | ||
* | ||
* - `$globals/$pathlike`. | ||
* | ||
* Where `$globals` is the directory of globally installed | ||
* npm packages. | ||
* | ||
* @example | ||
@@ -135,2 +156,3 @@ * var plugin = findPlugin('foo'); | ||
var current = resolve(cwd, 'node_modules', pathlike); | ||
var globalPath = resolve(globals, pathlike); | ||
var plugin; | ||
@@ -143,2 +165,4 @@ | ||
plugin = current; | ||
} else if (isGlobal && exists(globalPath)) { | ||
plugin = globalPath; | ||
} else { | ||
@@ -145,0 +169,0 @@ plugin = pathlike; |
{ | ||
"name": "remark-lint", | ||
"version": "2.1.0", | ||
"version": "2.2.0", | ||
"description": "Lint markdown with remark", | ||
@@ -21,2 +21,3 @@ "license": "MIT", | ||
"mdast-zone": "^2.0.0", | ||
"npm-prefix": "^1.1.1", | ||
"plur": "^2.0.0", | ||
@@ -23,0 +24,0 @@ "unist-util-visit": "^1.0.0", |
@@ -161,3 +161,3 @@ # ![remark-lint](https://cdn.rawgit.com/wooorm/remark-lint/master/logo.svg) | ||
* [`chcokr/remark-lint-sentence-newline`](https://github.com/chcokr/mdast-lint-sentence-newline) | ||
* [`chcokr/remark-lint-sentence-newline`](https://github.com/chcokr/remark-lint-sentence-newline) | ||
— Ensure sentences are followed by a newline; | ||
@@ -164,0 +164,0 @@ |
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
144047
4830
10
+ Addednpm-prefix@^1.1.1
+ Addeddeep-extend@0.6.0(transitive)
+ Addedini@1.3.8(transitive)
+ Addedminimist@1.2.8(transitive)
+ Addednpm-prefix@1.2.0(transitive)
+ Addedos-homedir@1.0.2(transitive)
+ Addedrc@1.2.8(transitive)
+ Addedshellsubstitute@1.2.0(transitive)
+ Addedstrip-json-comments@2.0.1(transitive)
+ Addeduntildify@2.1.0(transitive)