Skip to content

Commit 08fb4d8

Browse files
committed
chore: add .npmignore file and update package.json to include specific files in the "files" field
The .npmignore file is added to the project. It currently includes the file "out/github-action.cjs" to be ignored when publishing the package to npm. In the package.json file, the "files" field is updated to include the files "out/cli.cjs" and "out/tiktoken_bg.wasm". This ensures that these files are included when publishing the package to npm. The "deploy" script in the package.json file is also updated to include pushing tags to the remote repository using "git push --tags". This ensures that the newly created version tags are pushed along with the code changes.
1 parent 0460a25 commit 08fb4d8

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

.npmignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
out/github-action.cjs

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@
2626
"author": "https://github.com/di-sukharev",
2727
"license": "MIT",
2828
"files": [
29-
"out/**/*"
29+
"out/cli.cjs",
30+
"out/tiktoken_bg.wasm"
3031
],
3132
"release": {
3233
"branches": [
@@ -42,7 +43,7 @@
4243
"dev": "ts-node ./src/cli.ts",
4344
"build": "rimraf out && node esbuild.config.js",
4445
"build:push": "npm run build && git add . && git commit -m 'build' && git push",
45-
"deploy": "npm run build:push && npm version patch && git push --follow-tags && npm publish --tag latest",
46+
"deploy": "npm run build:push && npm version patch && git push --tags && npm publish --tag latest",
4647
"lint": "eslint src --ext ts && tsc --noEmit",
4748
"format": "prettier --write src"
4849
},

0 commit comments

Comments
 (0)