Skip to content

Commit f0d0f45

Browse files
committed
[fix #7]: update the scripts
1 parent bb66b94 commit f0d0f45

File tree

5 files changed

+37
-9
lines changed

5 files changed

+37
-9
lines changed

.eslintrc

Lines changed: 23 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,31 @@
11
{
2-
"extends": ["airbnb-base", "prettier"],
2+
"extends": ["eslint:recommended", "airbnb-base", "plugin:import/recommended", "prettier"],
33
"plugins": ["prettier", "import"],
4+
"parserOptions": {
5+
"sourceType": "module",
6+
"ecmaVersion": 2020
7+
},
8+
"env": {
9+
"node": true
10+
},
411
"rules": {
512
"no-console": ["off"],
613
"no-await-in-loop": ["off"],
14+
"import/order": [
15+
"error",
16+
{
17+
"newlines-between": "always",
18+
"alphabetize": { "order": "asc", "caseInsensitive": true }
19+
}
20+
],
721
"prettier/prettier": ["error"]
822
},
9-
"env": {
10-
"jest": true,
11-
"node": true
12-
}
23+
"overrides": [
24+
{
25+
"files": ["tests/**", "*.test.js", "*.spec.js"],
26+
"env": {
27+
"jest": true
28+
}
29+
}
30+
]
1331
}

package.json

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "rollup-plugin-copy-merge",
33
"description": "Copy & Merge files and folders using Rollup",
4-
"version": "0.3.0",
4+
"version": "0.3.1",
55
"author": "syJSdev <whitedragon226@gmail.com>",
66
"repository": "syJSdev/rollup-plugin-copy-merge",
77
"main": "dist/index.commonjs.js",
@@ -16,7 +16,9 @@
1616
"postpublish": "yarn clean",
1717
"prepublishOnly": "yarn lint && yarn test && yarn clean && yarn build",
1818
"test": "jest",
19-
"postinstall": "is-ci || husky install"
19+
"postinstall": "is-ci || husky install",
20+
"prepack": "pinst --disable",
21+
"postpack": "pinst --enable"
2022
},
2123
"dependencies": {
2224
"@types/fs-extra": "^9.0.13",
@@ -41,6 +43,7 @@
4143
"is-ci": "^3.0.1",
4244
"jest": "^28.1.0",
4345
"lint-staged": "^13.0.0",
46+
"pinst": "^3.0.0",
4447
"prettier": "^2.2.1",
4548
"replace-in-file": "^6.3.5",
4649
"rimraf": "^3.0.0",

rollup.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import path from 'node:path';
2+
23
import { babel } from '@rollup/plugin-babel';
34
import commonjs from '@rollup/plugin-commonjs';
45
import { nodeResolve as resolve } from '@rollup/plugin-node-resolve';

src/index.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
import path from 'node:path';
2+
3+
import { bold, green, yellow } from 'colorette';
24
import fs from 'fs-extra';
3-
import { isPlainObject } from 'is-plain-object';
45
import globby from 'globby';
5-
import { bold, green, yellow } from 'colorette';
6+
import { isPlainObject } from 'is-plain-object';
67

78
import { ensureTrailingNewLine, stringify } from './utils';
89

yarn.lock

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4391,6 +4391,11 @@ pidtree@^0.5.0:
43914391
resolved "https://registry.yarnpkg.com/pidtree/-/pidtree-0.5.0.tgz#ad5fbc1de78b8a5f99d6fbdd4f6e4eee21d1aca1"
43924392
integrity sha512-9nxspIM7OpZuhBxPg73Zvyq7j1QMPMPsGKTqRc2XOaFQauDvoNz9fM1Wdkjmeo7l9GXOZiRs97sPkuayl39wjA==
43934393

4394+
pinst@^3.0.0:
4395+
version "3.0.0"
4396+
resolved "https://registry.yarnpkg.com/pinst/-/pinst-3.0.0.tgz#80dec0a85f1f993c6084172020f3dbf512897eec"
4397+
integrity sha512-cengSmBxtCyaJqtRSvJorIIZXMXg+lJ3sIljGmtBGUVonMnMsVJbnzl6jGN1HkOWwxNuJynCJ2hXxxqCQrFDdw==
4398+
43944399
pirates@^4.0.4:
43954400
version "4.0.5"
43964401
resolved "https://registry.yarnpkg.com/pirates/-/pirates-4.0.5.tgz#feec352ea5c3268fb23a37c702ab1699f35a5f3b"

0 commit comments

Comments
 (0)