From d189759dcbe8a34e90e407ef25bf08b72c20785a Mon Sep 17 00:00:00 2001 From: Michael Dowse Date: Fri, 23 Feb 2024 11:24:02 +0100 Subject: [PATCH] chore: Publish from lib folder instead of dist --- .github/workflows/release.yml | 2 ++ .gitignore | 2 +- package.json | 8 +++----- tsconfig.json | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index e2fb7d8..d04c759 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -16,3 +16,5 @@ jobs: release: uses: cloudscape-design/actions/.github/workflows/release.yml@main secrets: inherit + with: + publish-packages: lib diff --git a/.gitignore b/.gitignore index 27d0955..6ca93eb 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,4 @@ build -dist +lib node_modules coverage diff --git a/package.json b/package.json index 52f747a..bcbc3d9 100644 --- a/package.json +++ b/package.json @@ -6,15 +6,13 @@ "url": "https://github.com/cloudscape-design/documenter.git" }, "homepage": "https://cloudscape.design", - "main": "./dist/index.js", - "files": [ - "dist" - ], + "main": "./index.js", "scripts": { "lint": "eslint --ignore-path .gitignore --ext js,ts,tsx .", + "prebuild": "rm -rf lib", "build": "tsc", + "postbuild": "cp package.json README.md LICENSE lib", "test": "jest", - "prepublishOnly": "npm run build", "prepare": "husky install" }, "devDependencies": { diff --git a/tsconfig.json b/tsconfig.json index a3f53a3..4c7c01b 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -5,7 +5,7 @@ "types": ["node"], "lib": ["es2019"], "declaration": true, - "outDir": "./dist", + "outDir": "./lib", "strict": true, "allowSyntheticDefaultImports": true, "esModuleInterop": true,