piclist 1.9.14 → 2.0.1
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/.github/workflows/docker.yml +5 -5
- package/CHANGELOG.md +19 -0
- package/License +22 -22
- package/README.md +1 -1
- package/README_cn.md +1 -1
- package/bin/picgo +9 -7
- package/bin/picgo-server +180 -161
- package/dist/core/Lifecycle.d.ts +35 -36
- package/dist/core/PicGo.d.ts +52 -52
- package/dist/i18n/en.d.ts +2 -2
- package/dist/i18n/index.d.ts +19 -17
- package/dist/i18n/zh-CN.d.ts +293 -289
- package/dist/i18n/zh-TW.d.ts +2 -2
- package/dist/index.d.ts +10 -10
- package/dist/index.js +2 -0
- package/dist/lib/Commander.d.ts +22 -22
- package/dist/lib/LifecyclePlugins.d.ts +26 -26
- package/dist/lib/Logger.d.ts +19 -19
- package/dist/lib/PluginHandler.d.ts +10 -10
- package/dist/lib/PluginLoader.d.ts +27 -27
- package/dist/lib/Request.d.ts +12 -12
- package/dist/plugins/beforetransformer/compress.d.ts +5 -5
- package/dist/plugins/beforetransformer/skipProcess.d.ts +5 -5
- package/dist/plugins/beforetransformer/watermark.d.ts +5 -5
- package/dist/plugins/beforeupload/buildInRename.d.ts +5 -5
- package/dist/plugins/commander/config.d.ts +3 -3
- package/dist/plugins/commander/i18n.d.ts +3 -3
- package/dist/plugins/commander/index.d.ts +3 -3
- package/dist/plugins/commander/pluginHandler.d.ts +3 -3
- package/dist/plugins/commander/proxy.d.ts +3 -3
- package/dist/plugins/commander/setting.d.ts +5 -5
- package/dist/plugins/commander/upload.d.ts +3 -3
- package/dist/plugins/commander/use.d.ts +3 -3
- package/dist/plugins/commander/utils.d.ts +2 -2
- package/dist/plugins/transformer/base64.d.ts +5 -5
- package/dist/plugins/transformer/index.d.ts +5 -5
- package/dist/plugins/transformer/path.d.ts +5 -5
- package/dist/plugins/uploader/advancedplist.d.ts +2 -2
- package/dist/plugins/uploader/alist.d.ts +2 -2
- package/dist/plugins/uploader/aliyun.d.ts +2 -2
- package/dist/plugins/uploader/awss3plist.d.ts +2 -2
- package/dist/plugins/uploader/github.d.ts +2 -2
- package/dist/plugins/uploader/imgur.d.ts +2 -2
- package/dist/plugins/uploader/index.d.ts +5 -5
- package/dist/plugins/uploader/local.d.ts +2 -2
- package/dist/plugins/uploader/lsky.d.ts +20 -21
- package/dist/plugins/uploader/piclist.d.ts +2 -2
- package/dist/plugins/uploader/qiniu.d.ts +2 -2
- package/dist/plugins/uploader/s3/uploader.d.ts +25 -24
- package/dist/plugins/uploader/s3/utils.d.ts +9 -10
- package/dist/plugins/uploader/sftp.d.ts +2 -2
- package/dist/plugins/uploader/smms.d.ts +2 -2
- package/dist/plugins/uploader/tcyun.d.ts +8 -8
- package/dist/plugins/uploader/upyun.d.ts +2 -2
- package/dist/plugins/uploader/utils.d.ts +26 -26
- package/dist/plugins/uploader/webdav.d.ts +2 -2
- package/dist/types/index.d.ts +572 -693
- package/dist/types/oldRequest.d.ts +15 -15
- package/dist/utils/common.d.ts +42 -119
- package/dist/utils/createContext.d.ts +6 -6
- package/dist/utils/db.d.ts +17 -15
- package/dist/utils/enum.d.ts +27 -27
- package/dist/utils/eventBus.d.ts +3 -4
- package/dist/utils/getClipboardImage.d.ts +4 -4
- package/dist/utils/sshClient.d.ts +16 -16
- package/dist/utils/static.d.ts +1 -1
- package/docker-compose.yaml +11 -11
- package/eslint.config.js +104 -0
- package/package.json +61 -78
- package/rollup.config.js +25 -42
- package/.eslintignore +0 -6
- package/.eslintrc.js +0 -50
- package/.github/workflows/alpha.yml +0 -22
- package/.github/workflows/main.yml +0 -22
- package/.github/workflows/manually.yml +0 -19
- package/dist/index.cjs.js +0 -2
- package/dist/index.esm.js +0 -2
- package/dist/plugins/commander/init.d.ts +0 -3
- package/dist/utils/initUtils.d.ts +0 -26
- package/dist/utils/interfaces.d.ts +0 -201
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "piclist",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "2.0.1",
|
|
4
4
|
"description": "Modified PicGo core, A tool for picture uploading",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Kuingsmile",
|
|
@@ -11,8 +11,9 @@
|
|
|
11
11
|
"url": "https://github.com/Kuingsmile/PicList-core/issues",
|
|
12
12
|
"email": "pkukuing@gmail.com"
|
|
13
13
|
},
|
|
14
|
-
"
|
|
15
|
-
"
|
|
14
|
+
"type": "module",
|
|
15
|
+
"main": "dist/index.js",
|
|
16
|
+
"module": "dist/index.js",
|
|
16
17
|
"typings": "dist/index.d.ts",
|
|
17
18
|
"bin": {
|
|
18
19
|
"picgo": "./bin/picgo",
|
|
@@ -24,7 +25,7 @@
|
|
|
24
25
|
"scripts": {
|
|
25
26
|
"start": "node ./bin/picgo",
|
|
26
27
|
"server": "node ./bin/picgo-server",
|
|
27
|
-
"lint": "eslint
|
|
28
|
+
"lint": "eslint",
|
|
28
29
|
"lint:fix": "eslint src/**/*.ts --fix",
|
|
29
30
|
"lint:dpdm": "dpdm -T --tsconfig ./tsconfig.json --no-tree --no-warning --exit-code circular:1 src/index.ts",
|
|
30
31
|
"dev": "cross-env NODE_ENV=development rollup -c rollup.config.js -w",
|
|
@@ -38,111 +39,93 @@
|
|
|
38
39
|
"upload",
|
|
39
40
|
"util"
|
|
40
41
|
],
|
|
41
|
-
"husky": {
|
|
42
|
-
"hooks": {
|
|
43
|
-
"commit-msg": "commitlint -E HUSKY_GIT_PARAMS"
|
|
44
|
-
}
|
|
45
|
-
},
|
|
46
42
|
"config": {
|
|
47
43
|
"commitizen": {
|
|
48
44
|
"path": "./node_modules/cz-customizable"
|
|
49
45
|
},
|
|
50
46
|
"cz-customizable": {
|
|
51
|
-
"config": "./node_modules/node-bump-version/.cz-config.
|
|
47
|
+
"config": "./node_modules/node-bump-version/.cz-config.cjs"
|
|
52
48
|
}
|
|
53
49
|
},
|
|
54
50
|
"commitlint": {
|
|
55
51
|
"extends": [
|
|
56
|
-
"./node_modules/node-bump-version/commitlint-node"
|
|
52
|
+
"./node_modules/node-bump-version/dist/commitlint-node/index.js"
|
|
57
53
|
]
|
|
58
54
|
},
|
|
59
55
|
"license": "MIT",
|
|
60
56
|
"devDependencies": {
|
|
61
|
-
"@
|
|
62
|
-
"@
|
|
63
|
-
"@
|
|
64
|
-
"@rollup/plugin-
|
|
65
|
-
"@
|
|
66
|
-
"@
|
|
57
|
+
"@eslint/compat": "^1.3.2",
|
|
58
|
+
"@eslint/eslintrc": "^3.3.1",
|
|
59
|
+
"@eslint/js": "^9.33.0",
|
|
60
|
+
"@rollup/plugin-commonjs": "^28.0.6",
|
|
61
|
+
"@rollup/plugin-json": "^6.1.0",
|
|
62
|
+
"@rollup/plugin-node-resolve": "^16.0.1",
|
|
63
|
+
"@rollup/plugin-replace": "^6.0.2",
|
|
64
|
+
"@rollup/plugin-terser": "^0.4.4",
|
|
65
|
+
"@rollup/plugin-typescript": "^12.1.4",
|
|
66
|
+
"@types/cross-spawn": "^6.0.6",
|
|
67
67
|
"@types/fs-extra": "^11.0.4",
|
|
68
|
-
"@types/heic-convert": "^1.
|
|
68
|
+
"@types/heic-convert": "^2.1.0",
|
|
69
69
|
"@types/image-size": "^0.8.0",
|
|
70
70
|
"@types/inquirer": "^0.0.42",
|
|
71
71
|
"@types/js-yaml": "^4.0.9",
|
|
72
|
-
"@types/lodash": "^4.
|
|
73
|
-
"@types/
|
|
74
|
-
"@types/
|
|
75
|
-
"@types/minimatch": "^3.0.3",
|
|
76
|
-
"@types/node": "16.11.7",
|
|
77
|
-
"@types/resolve": "^0.0.8",
|
|
72
|
+
"@types/lodash-es": "^4.17.12",
|
|
73
|
+
"@types/node": "24.2.1",
|
|
74
|
+
"@types/resolve": "^1.20.6",
|
|
78
75
|
"@types/text-to-svg": "^3.1.4",
|
|
79
|
-
"@types/tunnel": "^0.0.
|
|
80
|
-
"@
|
|
81
|
-
"@typescript-eslint/
|
|
82
|
-
"
|
|
83
|
-
"babel-eslint": "^10.1.0",
|
|
84
|
-
"builtins": "^4.0.0",
|
|
85
|
-
"conventional-changelog": "^3.0.6",
|
|
86
|
-
"cross-env": "^7.0.3",
|
|
87
|
-
"cz-customizable": "^5.10.0",
|
|
76
|
+
"@types/tunnel": "^0.0.7",
|
|
77
|
+
"@typescript-eslint/eslint-plugin": "^8.40.0",
|
|
78
|
+
"@typescript-eslint/parser": "^8.40.0",
|
|
79
|
+
"cross-env": "^10.0.0",
|
|
88
80
|
"dpdm": "^3.14.0",
|
|
89
|
-
"eslint": "^
|
|
90
|
-
"eslint-config-prettier": "^
|
|
91
|
-
"eslint-
|
|
92
|
-
"eslint-plugin-import": "^
|
|
93
|
-
"eslint-plugin-
|
|
94
|
-
"
|
|
95
|
-
"
|
|
96
|
-
"
|
|
97
|
-
"
|
|
98
|
-
"pre-commit": "^1.2.2",
|
|
99
|
-
"prettier": "^3.3.2",
|
|
100
|
-
"rollup": "^2.79.1",
|
|
81
|
+
"eslint": "^9.33.0",
|
|
82
|
+
"eslint-config-prettier": "^10.1.8",
|
|
83
|
+
"eslint-plugin-prettier": "^5.5.4",
|
|
84
|
+
"eslint-plugin-simple-import-sort": "^12.1.1",
|
|
85
|
+
"eslint-plugin-unicorn": "^60.0.0",
|
|
86
|
+
"husky": "^9.1.7",
|
|
87
|
+
"node-bump-version": "^2.0.0",
|
|
88
|
+
"prettier": "^3.6.2",
|
|
89
|
+
"rollup": "^4.46.1",
|
|
101
90
|
"rollup-plugin-copy": "^3.5.0",
|
|
102
91
|
"rollup-plugin-string": "^3.0.0",
|
|
103
|
-
"
|
|
104
|
-
"
|
|
105
|
-
"
|
|
92
|
+
"typescript": "^5.8.3",
|
|
93
|
+
"typescript-eslint": "^8.40.0",
|
|
94
|
+
"rimraf": "^6.0.1"
|
|
106
95
|
},
|
|
107
96
|
"dependencies": {
|
|
108
|
-
"@aws-sdk/client-s3": "3.
|
|
109
|
-
"@aws-sdk/lib-storage": "3.
|
|
110
|
-
"@aws-sdk/s3-request-presigner": "3.
|
|
111
|
-
"@
|
|
112
|
-
"@
|
|
113
|
-
"@smithy/node-http-handler": "
|
|
114
|
-
"axios": "^1.
|
|
115
|
-
"chalk": "^
|
|
97
|
+
"@aws-sdk/client-s3": "3.864.0",
|
|
98
|
+
"@aws-sdk/lib-storage": "3.864.0",
|
|
99
|
+
"@aws-sdk/s3-request-presigner": "3.864.0",
|
|
100
|
+
"@piclist/store": "^3.0.0",
|
|
101
|
+
"@piclist/i18n": "^2.0.0",
|
|
102
|
+
"@smithy/node-http-handler": "4.1.1",
|
|
103
|
+
"axios": "^1.11.0",
|
|
104
|
+
"chalk": "^5.4.1",
|
|
116
105
|
"commander": "^8.1.0",
|
|
117
|
-
"cross-spawn": "^7.0.
|
|
106
|
+
"cross-spawn": "^7.0.6",
|
|
118
107
|
"dayjs": "^1.11.13",
|
|
119
|
-
"
|
|
120
|
-
"
|
|
121
|
-
"
|
|
122
|
-
"
|
|
123
|
-
"fs-extra": "^11.3.0",
|
|
124
|
-
"globby": "^11.1.0",
|
|
125
|
-
"heic-convert": "^1.2.4",
|
|
108
|
+
"file-type": "21.0.0",
|
|
109
|
+
"form-data": "^4.0.4",
|
|
110
|
+
"fs-extra": "^11.3.1",
|
|
111
|
+
"heic-convert": "^2.1.0",
|
|
126
112
|
"hpagent": "1.2.0",
|
|
127
|
-
"image-size": "^
|
|
113
|
+
"image-size": "^2.0.2",
|
|
128
114
|
"inquirer": "^6.0.0",
|
|
129
|
-
"is-wsl": "^
|
|
115
|
+
"is-wsl": "^3.1.0",
|
|
130
116
|
"js-yaml": "^4.1.0",
|
|
131
|
-
"lodash": "^4.17.21",
|
|
132
|
-
"mime": "
|
|
133
|
-
"mime-types": "2.1.35",
|
|
134
|
-
"minimatch": "^3.0.4",
|
|
117
|
+
"lodash-es": "^4.17.21",
|
|
118
|
+
"mime": "4.0.7",
|
|
135
119
|
"minimist": "^1.2.8",
|
|
136
|
-
"multer": "^
|
|
120
|
+
"multer": "^2.0.2",
|
|
137
121
|
"node-ssh-no-cpu-features": "^2.0.0",
|
|
138
|
-
"qiniu": "7.
|
|
139
|
-
"resolve": "^1.
|
|
140
|
-
"
|
|
141
|
-
"sharp": "^0.32.1",
|
|
122
|
+
"qiniu": "7.14.0",
|
|
123
|
+
"resolve": "^1.22.10",
|
|
124
|
+
"sharp": "^0.34.3",
|
|
142
125
|
"text-to-svg": "^3.1.5",
|
|
143
126
|
"tunnel": "^0.0.6",
|
|
144
|
-
"uuid": "^
|
|
145
|
-
"webdav": "^
|
|
127
|
+
"uuid": "^11.1.0",
|
|
128
|
+
"webdav": "^5.8.0"
|
|
146
129
|
},
|
|
147
130
|
"repository": {
|
|
148
131
|
"type": "git",
|
|
@@ -153,6 +136,6 @@
|
|
|
153
136
|
},
|
|
154
137
|
"plugins": {},
|
|
155
138
|
"engines": {
|
|
156
|
-
"node": ">=
|
|
139
|
+
"node": ">=20.0.0"
|
|
157
140
|
}
|
|
158
141
|
}
|
package/rollup.config.js
CHANGED
|
@@ -1,12 +1,15 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
|
|
1
|
+
import { readFileSync } from 'node:fs'
|
|
2
|
+
import { builtinModules } from 'node:module'
|
|
3
|
+
|
|
4
4
|
import commonjs from '@rollup/plugin-commonjs'
|
|
5
|
-
import copy from 'rollup-plugin-copy'
|
|
6
|
-
import { string } from 'rollup-plugin-string'
|
|
7
5
|
import json from '@rollup/plugin-json'
|
|
8
|
-
import builtins from 'builtins'
|
|
9
6
|
import replace from '@rollup/plugin-replace'
|
|
7
|
+
import terser from '@rollup/plugin-terser'
|
|
8
|
+
import typescript from '@rollup/plugin-typescript'
|
|
9
|
+
import copy from 'rollup-plugin-copy'
|
|
10
|
+
import { string } from 'rollup-plugin-string'
|
|
11
|
+
|
|
12
|
+
const pkg = JSON.parse(readFileSync('./package.json', 'utf8'))
|
|
10
13
|
|
|
11
14
|
const version = process.env.VERSION || pkg.version
|
|
12
15
|
const sourcemap = 'inline'
|
|
@@ -22,32 +25,21 @@ const commonOptions = {
|
|
|
22
25
|
// packages such as `lowdb/adapters/FileSync` are also treated as external
|
|
23
26
|
// See https://github.com/rollup/rollup/issues/3684#issuecomment-926558056
|
|
24
27
|
external: [
|
|
25
|
-
...Object.keys(pkg.dependencies),
|
|
26
|
-
...
|
|
27
|
-
]
|
|
28
|
+
...Object.keys(pkg.dependencies).map(packageName => new RegExp(`^${packageName}(/.*)?`)),
|
|
29
|
+
...builtinModules.map(moduleName => new RegExp(`^(node:)?${moduleName}(/.*)?`))
|
|
30
|
+
],
|
|
28
31
|
plugins: [
|
|
29
32
|
typescript({
|
|
30
|
-
|
|
31
|
-
compilerOptions: {
|
|
32
|
-
target: 'ES2017',
|
|
33
|
-
module: 'ES2015'
|
|
34
|
-
}
|
|
35
|
-
}
|
|
33
|
+
tsconfig: './tsconfig.json'
|
|
36
34
|
}),
|
|
37
35
|
copy({
|
|
38
|
-
targets: [
|
|
39
|
-
{ src: 'assets', dest: 'dist' }
|
|
40
|
-
]
|
|
36
|
+
targets: [{ src: 'assets', dest: 'dist' }]
|
|
41
37
|
}),
|
|
42
38
|
// terser(),
|
|
43
39
|
commonjs(),
|
|
44
40
|
string({
|
|
45
41
|
// Required to be specified
|
|
46
|
-
include: [
|
|
47
|
-
'**/*.applescript',
|
|
48
|
-
'**/*.ps1',
|
|
49
|
-
'**/*.sh'
|
|
50
|
-
]
|
|
42
|
+
include: ['**/*.applescript', '**/*.ps1', '**/*.sh']
|
|
51
43
|
}),
|
|
52
44
|
json(),
|
|
53
45
|
replace({
|
|
@@ -65,30 +57,21 @@ if (!isDev) {
|
|
|
65
57
|
}
|
|
66
58
|
|
|
67
59
|
/** @type import('rollup').RollupOptions */
|
|
68
|
-
const nodeCjs = {
|
|
69
|
-
output: [{
|
|
70
|
-
file: 'dist/index.cjs.js',
|
|
71
|
-
format: 'cjs',
|
|
72
|
-
banner,
|
|
73
|
-
sourcemap
|
|
74
|
-
}],
|
|
75
|
-
...commonOptions
|
|
76
|
-
}
|
|
77
60
|
|
|
78
61
|
const nodeEsm = {
|
|
79
|
-
output: [
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
62
|
+
output: [
|
|
63
|
+
{
|
|
64
|
+
file: 'dist/index.js',
|
|
65
|
+
format: 'esm',
|
|
66
|
+
banner,
|
|
67
|
+
sourcemap
|
|
68
|
+
}
|
|
69
|
+
],
|
|
85
70
|
...commonOptions
|
|
86
71
|
}
|
|
87
72
|
|
|
88
73
|
const bundles = []
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
if (env.includes('esm')) bundles.push(nodeEsm)
|
|
92
|
-
if (bundles.length === 0) bundles.push(nodeCjs, nodeEsm)
|
|
74
|
+
|
|
75
|
+
bundles.push(nodeEsm)
|
|
93
76
|
|
|
94
77
|
export default bundles
|
package/.eslintignore
DELETED
package/.eslintrc.js
DELETED
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
module.exports = {
|
|
2
|
-
extends: [
|
|
3
|
-
'eslint:recommended',
|
|
4
|
-
'plugin:@typescript-eslint/recommended',
|
|
5
|
-
'plugin:import/recommended',
|
|
6
|
-
'plugin:import/typescript',
|
|
7
|
-
'plugin:n/recommended',
|
|
8
|
-
'plugin:prettier/recommended',
|
|
9
|
-
],
|
|
10
|
-
parser: '@typescript-eslint/parser',
|
|
11
|
-
plugins: ['@typescript-eslint', 'import'],
|
|
12
|
-
rules: {
|
|
13
|
-
// https://github.com/typescript-eslint/typescript-eslint/blob/ef88a696a157f617d38ce6d49207a4a4a089a19b/packages/eslint-plugin/docs/rules/naming-convention.md#enforce-that-interface-names-do-not-begin-with-an-i
|
|
14
|
-
'@typescript-eslint/naming-convention': [
|
|
15
|
-
'error',
|
|
16
|
-
{
|
|
17
|
-
selector: 'interface',
|
|
18
|
-
format: ['PascalCase'],
|
|
19
|
-
custom: {
|
|
20
|
-
regex: '^I[A-Z]',
|
|
21
|
-
match: true,
|
|
22
|
-
},
|
|
23
|
-
},
|
|
24
|
-
],
|
|
25
|
-
'@typescript-eslint/prefer-nullish-coalescing': 0,
|
|
26
|
-
'@typescript-eslint/no-non-null-assertion': 0,
|
|
27
|
-
'@typescript-eslint/no-explicit-any': 0,
|
|
28
|
-
'import/no-named-as-default': 0,
|
|
29
|
-
'n/no-missing-import': 0,
|
|
30
|
-
'n/no-process-exit': 0,
|
|
31
|
-
'prettier/prettier': [
|
|
32
|
-
'error',
|
|
33
|
-
{},
|
|
34
|
-
{
|
|
35
|
-
usePrettierrc: true,
|
|
36
|
-
},
|
|
37
|
-
],
|
|
38
|
-
},
|
|
39
|
-
settings: {
|
|
40
|
-
'import/parsers': {
|
|
41
|
-
'@typescript-eslint/parser': ['.ts', '.tsx'],
|
|
42
|
-
},
|
|
43
|
-
'import/resolver': {
|
|
44
|
-
typescript: {
|
|
45
|
-
alwaysTryTypes: true,
|
|
46
|
-
project: './tsconfig.json',
|
|
47
|
-
},
|
|
48
|
-
}
|
|
49
|
-
},
|
|
50
|
-
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
name: publish
|
|
2
|
-
on:
|
|
3
|
-
push:
|
|
4
|
-
branches:
|
|
5
|
-
- alpha
|
|
6
|
-
jobs:
|
|
7
|
-
build:
|
|
8
|
-
runs-on: ubuntu-latest
|
|
9
|
-
steps:
|
|
10
|
-
- name: Clone repo
|
|
11
|
-
uses: actions/checkout@v1
|
|
12
|
-
- name: Setup node
|
|
13
|
-
uses: actions/setup-node@v1
|
|
14
|
-
with:
|
|
15
|
-
node-version: '16.x'
|
|
16
|
-
registry-url: 'https://registry.npmjs.org'
|
|
17
|
-
- name: Install modules
|
|
18
|
-
run: yarn
|
|
19
|
-
- run: npm run build
|
|
20
|
-
- run: npm publish --tag alpha --access public
|
|
21
|
-
env:
|
|
22
|
-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
name: publish
|
|
2
|
-
on:
|
|
3
|
-
push:
|
|
4
|
-
branches:
|
|
5
|
-
- master
|
|
6
|
-
jobs:
|
|
7
|
-
build:
|
|
8
|
-
runs-on: ubuntu-latest
|
|
9
|
-
steps:
|
|
10
|
-
- name: Clone repo
|
|
11
|
-
uses: actions/checkout@v1
|
|
12
|
-
- name: Setup node
|
|
13
|
-
uses: actions/setup-node@v1
|
|
14
|
-
with:
|
|
15
|
-
node-version: '16.x'
|
|
16
|
-
registry-url: 'https://registry.npmjs.org'
|
|
17
|
-
- name: Install modules
|
|
18
|
-
run: yarn
|
|
19
|
-
- run: npm run build
|
|
20
|
-
- run: npm publish --access public
|
|
21
|
-
env:
|
|
22
|
-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
name: manually-trigger
|
|
2
|
-
on: workflow_dispatch
|
|
3
|
-
jobs:
|
|
4
|
-
build:
|
|
5
|
-
runs-on: ubuntu-latest
|
|
6
|
-
steps:
|
|
7
|
-
- name: Clone repo
|
|
8
|
-
uses: actions/checkout@v1
|
|
9
|
-
- name: Setup node
|
|
10
|
-
uses: actions/setup-node@v1
|
|
11
|
-
with:
|
|
12
|
-
node-version: '16.x'
|
|
13
|
-
registry-url: 'https://registry.npmjs.org'
|
|
14
|
-
- name: Install modules
|
|
15
|
-
run: yarn
|
|
16
|
-
- run: npm run build
|
|
17
|
-
- run: npm publish --access public
|
|
18
|
-
env:
|
|
19
|
-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|