Skip to content

Commit

Permalink
refactor: using ncc and skip dist test
Browse files Browse the repository at this point in the history
  • Loading branch information
alistairstead committed Jun 23, 2023
1 parent 49babd5 commit a60613d
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 19 deletions.
26 changes: 13 additions & 13 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
- main

jobs:
build:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -49,15 +49,15 @@ jobs:
- name: test
run: pnpm run test

- name: build
run: pnpm run build

- run: |
mkdir -p .sst/dist
touch .sst/dist/manifest.json
echo '{"version": "31.0.0","artifacts": {}}' > .sst/dist/manifest.json
touch sst.config.ts
- uses: ./
with:
stage: production
# - name: build
# run: pnpm run build
#
# - run: |
# mkdir -p .sst/dist
# touch .sst/dist/manifest.json
# echo '{"version": "31.0.0","artifacts": {}}' > .sst/dist/manifest.json
# touch sst.config.ts
#
# - uses: ./
# with:
# stage: production
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@
"node": "^16.0.0"
},
"scripts": {
"build": "ncc build src/index.ts -o dist --transpile-only --minify",
"build": "ncc build src/index.ts -o dist --source-map --license licenses.txt --minify",
"format": "prettier --write '**/*.ts'",
"format-check": "prettier --check '**/*.ts'",
"lint": "eslint src/**/*.ts",
"test": "vitest run",
"act": "npm run package && act -j test -W .github/workflows/test.yml",
"act": "npm run build && act -j test -W .github/workflows/ci.yml",
"clean:dist": "git filter-branch --index-filter 'git rm -rf --cached --ignore-unmatch dist' HEAD",
"bump": "node ./scripts/bump.cjs",
"release": "node ./scripts/release.cjs"
"bump": "node ./scripts/bump.js",
"release": "node ./scripts/release.js"
},
"repository": {
"type": "git",
Expand Down
8 changes: 6 additions & 2 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
{
"extends": "@tsconfig/node16/tsconfig.json",
"compilerOptions": {
"target": "ESNEXT"
"target": "esnext",
"module": "commonjs",
"noEmit": true,
"isolatedModules": true,
"strict": true,
"esModuleInterop": true
}
}

0 comments on commit a60613d

Please sign in to comment.