@initx-plugin/cp 0.0.18 → 0.0.19
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 +6 -0
- package/dist/index.mjs +9 -18
- package/package.json +11 -11
package/README.md
CHANGED
package/dist/index.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import os from 'node:os';
|
|
2
|
-
import { cwd } from 'node:process';
|
|
3
1
|
import { existsSync, readdirSync, readFileSync } from 'node:fs';
|
|
2
|
+
import os from 'node:os';
|
|
4
3
|
import { resolve } from 'node:path';
|
|
5
|
-
import
|
|
4
|
+
import { cwd } from 'node:process';
|
|
6
5
|
import { InitxPlugin } from '@initx-plugin/core';
|
|
7
6
|
import { log, inquirer, gpgList, c } from '@initx-plugin/utils';
|
|
7
|
+
import clipboard from 'clipboardy';
|
|
8
8
|
|
|
9
9
|
var CpType = /* @__PURE__ */ ((CpType2) => {
|
|
10
10
|
CpType2["SSH"] = "ssh";
|
|
@@ -13,22 +13,13 @@ var CpType = /* @__PURE__ */ ((CpType2) => {
|
|
|
13
13
|
return CpType2;
|
|
14
14
|
})(CpType || {});
|
|
15
15
|
|
|
16
|
-
var __defProp = Object.defineProperty;
|
|
17
|
-
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
18
|
-
var __publicField = (obj, key, value) => {
|
|
19
|
-
__defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
20
|
-
return value;
|
|
21
|
-
};
|
|
22
16
|
class CpPlugin extends InitxPlugin {
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
}
|
|
30
|
-
]);
|
|
31
|
-
}
|
|
17
|
+
matchers = [
|
|
18
|
+
{
|
|
19
|
+
matching: "cp",
|
|
20
|
+
description: "Copy SSH public key"
|
|
21
|
+
}
|
|
22
|
+
];
|
|
32
23
|
async handle(_ctx, cpType, ...others) {
|
|
33
24
|
if (!cpType || typeof this[cpType] !== "function") {
|
|
34
25
|
const typeList = CpType;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@initx-plugin/cp",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.19",
|
|
5
5
|
"description": "initx plugin, copy some text to clipboard",
|
|
6
6
|
"author": "imba97",
|
|
7
7
|
"license": "MIT",
|
|
@@ -24,20 +24,20 @@
|
|
|
24
24
|
"dist"
|
|
25
25
|
],
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@initx-plugin/core": "^0.0.
|
|
28
|
-
"@initx-plugin/utils": "^0.0.
|
|
27
|
+
"@initx-plugin/core": "^0.0.27",
|
|
28
|
+
"@initx-plugin/utils": "^0.0.27",
|
|
29
29
|
"clipboardy": "^4.0.0"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
|
-
"@imba97/eslint-config": "^0.0.
|
|
33
|
-
"@types/node": "^22.
|
|
34
|
-
"bumpp": "^9.
|
|
35
|
-
"eslint": "^9.
|
|
36
|
-
"lint-staged": "^15.
|
|
32
|
+
"@imba97/eslint-config": "^0.0.5",
|
|
33
|
+
"@types/node": "^22.10.2",
|
|
34
|
+
"bumpp": "^9.9.2",
|
|
35
|
+
"eslint": "^9.17.0",
|
|
36
|
+
"lint-staged": "^15.3.0",
|
|
37
37
|
"simple-git-hooks": "^2.11.1",
|
|
38
|
-
"typescript": "5.
|
|
39
|
-
"unbuild": "^
|
|
40
|
-
"vitest": "^2.1.
|
|
38
|
+
"typescript": "^5.7.2",
|
|
39
|
+
"unbuild": "^3.1.0",
|
|
40
|
+
"vitest": "^2.1.8"
|
|
41
41
|
},
|
|
42
42
|
"simple-git-hooks": {
|
|
43
43
|
"pre-commit": "pnpm lint-staged"
|