intelli-espower-loader
Advanced tools
Comparing version 1.0.1 to 1.1.0
@@ -7,2 +7,3 @@ // LICENSE : MIT | ||
var packageName = require("../package.json").name; | ||
var packageNameReg = new RegExp('^' + packageName); // for support nodejs < 4.x, same as 'startsWith' | ||
@@ -16,4 +17,6 @@ function findPackageDir(paths) { | ||
var dirName = dir.split(path.sep).pop(); | ||
if (dirName !== packageName) { | ||
return dir; | ||
// ignore self and `.pnpm`. (support pnpm install) | ||
if (!packageNameReg.test(dirName) && dirName !== '.pnpm') { | ||
return dir; | ||
} | ||
@@ -33,2 +36,2 @@ } | ||
} | ||
module.exports = getPackageJSON; | ||
module.exports = getPackageJSON; |
{ | ||
"name": "intelli-espower-loader", | ||
"description": "Make espower-lodaer config file unnecessary.", | ||
"version": "1.0.1", | ||
"version": "1.1.0", | ||
"repository": { | ||
"url": "git://github.com/azu/intelli-espower-loader.git" | ||
"url": "git://github.com/power-assert-js/intelli-espower-loader.git" | ||
}, | ||
"main": "intelli-espower-loader.js", | ||
"scripts": { | ||
"test": "mocha test/*.js && (cd example && npm run travis-test)" | ||
"test": "mocha test/*.js && (cd example && npm run ci-test)" | ||
}, | ||
"files": [ | ||
"CHANGELOG.md", | ||
"LICENSE", | ||
"intelli-espower-loader.js", | ||
"lib", | ||
"package.json", | ||
"readme.md" | ||
], | ||
"directories": { | ||
@@ -18,3 +26,3 @@ "test": "test/" | ||
"bugs": { | ||
"url": "https://github.com/azu/intelli-espower-loader/issues" | ||
"url": "https://github.com/power-assert-js/intelli-espower-loader/issues" | ||
}, | ||
@@ -25,4 +33,4 @@ "dependencies": { | ||
"devDependencies": { | ||
"mocha": "^2.0.1" | ||
"mocha": "^8.0.0" | ||
} | ||
} |
@@ -1,4 +0,4 @@ | ||
# intelli-espower-loader [![Build Status](https://travis-ci.org/power-assert-js/intelli-espower-loader.svg?branch=master)](https://travis-ci.org/power-assert-js/intelli-espower-loader) | ||
# intelli-espower-loader [![Build Status][ci-image]][ci-url] | ||
Handy node module for [power-assert](https://github.com/twada/power-assert "power-assert") and [espower-loader](https://github.com/twada/espower-loader " espower-loader"). | ||
Handy node module for [power-assert](https://github.com/power-assert-js/power-assert "power-assert") and [espower-loader](https://github.com/power-assert-js/espower-loader " espower-loader"). | ||
@@ -11,3 +11,3 @@ ## Installation | ||
You should also install [power-assert](https://github.com/twada/power-assert "power-assert"). | ||
You should also install [power-assert](https://github.com/power-assert-js/power-assert "power-assert"). | ||
@@ -22,4 +22,9 @@ ```sh | ||
### 1. (Optional) You have to set test directory to your `package.json` | ||
### 1. Put test script in test folder | ||
The default folder is `"test/"`. You must put your test script in this folder. | ||
**If you don't put your test code in the right folder, intelli-espower-loader will work incorrectly.** | ||
You can change test folder setting in your `package.json` | ||
``` json | ||
@@ -44,4 +49,2 @@ { | ||
If you didn't set directories.test, use `"test/"` as default value. | ||
### 2. Run mocha with `intelli-espower-loader` | ||
@@ -53,7 +56,7 @@ | ||
Run Test with [power-assert](https://github.com/twada/power-assert "power-assert") on the fly!! | ||
Run Test with [power-assert](https://github.com/power-assert-js/power-assert "power-assert") on the fly!! | ||
![mocha](http://monosnap.com/image/GNvwDvnwXuUSvaGGZotBOeXwBATEfR.png) | ||
![mocha](https://monosnap.com/image/GNvwDvnwXuUSvaGGZotBOeXwBATEfR.png) | ||
![mocha with webstorm](http://monosnap.com/image/EKtgJNXyjzm32Ijiu7VubrZho4Rmc2.png) | ||
![mocha with webstorm](https://monosnap.com/image/EKtgJNXyjzm32Ijiu7VubrZho4Rmc2.png) | ||
@@ -72,1 +75,4 @@ | ||
MIT | ||
[ci-image]: https://github.com/power-assert-js/intelli-espower-loader/workflows/Node.js%20CI/badge.svg | ||
[ci-url]: https://github.com/power-assert-js/intelli-espower-loader/actions?query=workflow%3A%22Node.js+CI%22 |
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
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
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
No repository
Supply chain riskPackage does not have a linked source code repository. Without this field, a package will have no reference to the location of the source code use to generate the package.
Found 1 instance in 1 package
74
6416
8
69
1