@iobroker/repochecker 4.0.0-alpha.0 → 4.0.0-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/lib/M900_GitNpmIgnore.js +4 -4
- package/package.json +1 -1
package/README.md
CHANGED
package/lib/M900_GitNpmIgnore.js
CHANGED
|
@@ -65,7 +65,7 @@ async function checkGitIgnore(context) {
|
|
|
65
65
|
|
|
66
66
|
if (!tooComplexToCheck) {
|
|
67
67
|
checkFiles.forEach(file => {
|
|
68
|
-
if (context.filesList.includes(file)) {
|
|
68
|
+
if (context.filesList.includes(`/${file}`)) {
|
|
69
69
|
// maybe it is with regex
|
|
70
70
|
const check = rules.some(rule => {
|
|
71
71
|
if (typeof rule === 'string') {
|
|
@@ -116,7 +116,7 @@ async function checkNpmIgnore(context) {
|
|
|
116
116
|
|
|
117
117
|
// https://raw.githubusercontent.com/userName/ioBroker.adaptername/${context.branch}/.npmignore
|
|
118
118
|
if (context.packageJson.files && context.packageJson.files.length) {
|
|
119
|
-
if (context.filesList.includes('
|
|
119
|
+
if (context.filesList.includes('/.npmignore')) {
|
|
120
120
|
context.warnings.push(
|
|
121
121
|
`[W951] .npmignore found but "files" is used at package.json. Please remove .npmignore.`,
|
|
122
122
|
);
|
|
@@ -127,7 +127,7 @@ async function checkNpmIgnore(context) {
|
|
|
127
127
|
}
|
|
128
128
|
|
|
129
129
|
// package.json files section is NOT used
|
|
130
|
-
if (!context.filesList.includes('
|
|
130
|
+
if (!context.filesList.includes('/.npmignore')) {
|
|
131
131
|
context.errors.push(
|
|
132
132
|
`[E952] neither files section at package.json nor file .npmignore not found. npm package will contain unwanted files.`,
|
|
133
133
|
);
|
|
@@ -164,7 +164,7 @@ async function checkNpmIgnore(context) {
|
|
|
164
164
|
// }
|
|
165
165
|
|
|
166
166
|
checkFiles.forEach((file, i) => {
|
|
167
|
-
if (context.filesList.includes(file)) {
|
|
167
|
+
if (context.filesList.includes(`/${file}`)) {
|
|
168
168
|
// maybe it is with regex
|
|
169
169
|
const check = rules.some(rule => {
|
|
170
170
|
if (typeof rule === 'string') {
|
package/package.json
CHANGED