Skip to content

Commit

Permalink
ci(npm): build project before publishing
Browse files Browse the repository at this point in the history
  • Loading branch information
nvlang committed Jun 30, 2024
1 parent 4962f6a commit 7a2e0b2
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@ jobs:
- name: Install Dependencies
run: pnpm install

- name: Build
run: pnpm build

- name: Determine Branch
run:
echo "BRANCH_NAME=$(git rev-parse --abbrev-ref HEAD)" >> $GITHUB_ENV
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@
"homepage": "https://sveltex.dev",
"files": [
"dist",
"src",
"package.json",
"LICENSE",
"README.md"
Expand All @@ -45,10 +44,11 @@
"scripts": {
"start": "node dist/src/main.js",
"clean": "rimraf coverage dist tmp",
"copy:meta": "cp README.md dist/ && cp LICENSE dist/",
"prebuild": "pnpm run lint",
"build:dev": "tsc -p tsconfig.json && tsc-alias -p tsconfig.json",
"build:dev:watch": "tsc -w -p tsconfig.json",
"build": "pnpm run clean && tsc -p tsconfig.release.json && tsc-alias -p tsconfig.release.json",
"build": "pnpm run clean && tsc -p tsconfig.release.json && tsc-alias -p tsconfig.release.json && pnpm run copy:meta",
"lint": "eslint . && tsc -p tsconfig.check.json",
"test": "vitest run --coverage --watch --",
"test:e2e": "pnpm test:e2e:prepare && playwright test",
Expand Down
5 changes: 4 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,9 @@
"src",
"tests",
"src/scripts",
"scripts"
"scripts",
"LICENSE",
"README.md",
"CODE_OF_CONDUCT.md"
]
}

0 comments on commit 7a2e0b2

Please sign in to comment.