fix pkg warning

master
cyhhao 2 years ago
parent f4da12ac27
commit 07475f8431

@ -1,12 +1,7 @@
{ {
"name": "git3-cli", "name": "git3-cli",
"version": "1.0.0", "version": "1.0.0",
"main": "dist/index.js",
"type": "module", "type": "module",
"types": "dist/index.d.ts",
"files": [
"dist/"
],
"bin": "dist/index.js", "bin": "dist/index.js",
"pkg": { "pkg": {
"targets": [ "targets": [
@ -25,7 +20,6 @@
"colors-cli": "^1.0.28", "colors-cli": "^1.0.28",
"commander": "^9.4.1", "commander": "^9.4.1",
"debug": "^4.3.4", "debug": "^4.3.4",
"esbuild": "^0.16.4",
"eth-ens-namehash": "^2.0.8", "eth-ens-namehash": "^2.0.8",
"ethers": "^5.7.2", "ethers": "^5.7.2",
"git-config-path": "^2.0.0", "git-config-path": "^2.0.0",
@ -38,15 +32,16 @@
"superpathjoin": "^2.0.1" "superpathjoin": "^2.0.1"
}, },
"scripts": { "scripts": {
"build": "yarn run clean && tsc", "build": "yarn clean && tsc",
"install-mac": "yarn pkg && cp ./bin/git3-cli-macos-x64 /usr/local/bin/git-remote-git3", "install-mac": "yarn pkg && cp ./bin/index-macos-x64 /usr/local/bin/git-remote-git3",
"install-mac-arm": "yarn pkg && cp ./bin/git3-cli-macos-arm64 /usr/local/bin/git-remote-git3", "install-mac-arm": "yarn pkg && cp ./bin/index-macos-arm64 /usr/local/bin/git-remote-git3",
"pkg": "yarn run build && pkg .", "pkg": "yarn build && pkg ./dist/index.js --out-path bin/ --targets node18-macos-x64,node18-macos-arm64,node18-linux-x64,node18-win-x64",
"build:git3": "esbuild ./src/git3/index.js --bundle --platform=node --target=es6 --outfile=dist/git3.js", "build:git3": "esbuild ./src/git3/index.js --bundle --platform=node --target=es6 --outfile=dist/git3.js",
"pkg:git3": "yarn build:git3 && pkg dist/git3.js --output bin/git3 && cp bin/git3 /usr/local/bin/git3", "pkg:git3": "yarn build:git3 && pkg dist/git3.js --output bin/git3 && cp bin/git3 /usr/local/bin/git3",
"clean": "rm -rf ./dist ./bin" "clean": "rm -rf ./dist ./bin"
}, },
"devDependencies": { "devDependencies": {
"esbuild": "^0.16.4",
"@types/buffer-split": "^1.0.0", "@types/buffer-split": "^1.0.0",
"@types/debug": "^4.1.7", "@types/debug": "^4.1.7",
"@types/node": "^18.11.10", "@types/node": "^18.11.10",

@ -11,7 +11,7 @@
"es5", "es5",
"es6" "es6"
], /* Specify library files to be included in the compilation. */ ], /* Specify library files to be included in the compilation. */
"allowJs": true, /* Allow javascript files to be compiled. */ "allowJs": true, /* Allow javascript files to be compiled. */
// "checkJs": true, /* Report errors in .js files. */ // "checkJs": true, /* Report errors in .js files. */
// "jsx": "preserve", /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */ // "jsx": "preserve", /* Specify JSX code generation: 'preserve', 'react-native', or 'react'. */
"declaration": true, /* Generates corresponding '.d.ts' file. */ "declaration": true, /* Generates corresponding '.d.ts' file. */
@ -64,6 +64,7 @@
"exclude": [ "exclude": [
"node_modules", "node_modules",
"test", "test",
"types" "types",
"src/git3"
] ]
} }
Loading…
Cancel
Save