Skip to content

Commit

Permalink
build: remove support for packaging the library (#4)
Browse files Browse the repository at this point in the history
* build: remove support for packaging library

Signed-off-by: Alfi Maulana <[email protected]>

* build: configure TypeScript to only build bin script without declarations

Signed-off-by: Alfi Maulana <[email protected]>

---------

Signed-off-by: Alfi Maulana <[email protected]>
  • Loading branch information
threeal authored Nov 9, 2024
1 parent a65be4f commit eb3bc73
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 21 deletions.
13 changes: 3 additions & 10 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,8 @@ jobs:
- name: Check Lint
run: yarn lint

- name: Build Library
run: yarn build

- name: Test Library
run: yarn test

- name: Package Library
run: yarn pack

- name: Upload Package
uses: actions/[email protected]
with:
path: package.tgz
if-no-files-found: error
overwrite: true
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,3 @@

dist/
node_modules/

package.tgz
6 changes: 0 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,11 @@
"name": "my_bot",
"private": true,
"type": "module",
"main": "dist/index.js",
"types": "dist/index.d.ts",
"bin": "dist/bin.js",
"files": [
"dist"
],
"scripts": {
"build": "tsc",
"format": "prettier --write --cache .",
"lint": "eslint",
"prepack": "tsc",
"test": "jest"
},
"dependencies": {
Expand Down
4 changes: 1 addition & 3 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
{
"include": ["src"],
"exclude": ["**/*.test.*"],
"include": ["src/bin.ts"],
"compilerOptions": {
"exactOptionalPropertyTypes": true,
"strict": true,
"module": "node16",
"declaration": true,
"outDir": "dist",
"esModuleInterop": true,
"target": "es2022",
Expand Down

0 comments on commit eb3bc73

Please sign in to comment.