From 065fa9c4d0cdad8e6979ab593bdce7e08eff8266 Mon Sep 17 00:00:00 2001 From: Moreno Feltscher Date: Tue, 20 Dec 2022 10:45:20 +0100 Subject: [PATCH] fix: Release job not working --- .github/workflows/release.yml | 22 ++++++++++------------ .gitignore | 2 +- config/tsconfig.base.json | 2 +- config/tsconfig.build.json | 3 --- package.json | 12 ++++-------- 5 files changed, 16 insertions(+), 25 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index bbf0ffb..972e2cb 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,25 +1,23 @@ -name: Release +name: Release npm package + on: push: branches: - master + jobs: release: name: Release runs-on: ubuntu-latest steps: - - name: Checkout - uses: actions/checkout@v2 + - uses: actions/checkout@main + - uses: actions/setup-node@v3 with: - fetch-depth: 0 - - name: Setup Node.js - uses: actions/setup-node@v2 - with: - node-version: "lts/*" - - name: Install dependencies - run: npm ci - - name: Release + node-version: '18.x' + - run: npm install + - run: npm run build + - name: semantic release + uses: cycjimmy/semantic-release-action@v3 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} NPM_TOKEN: ${{ secrets.NPM_TOKEN }} - run: npx semantic-release diff --git a/.gitignore b/.gitignore index 030065e..37c8161 100644 --- a/.gitignore +++ b/.gitignore @@ -13,7 +13,7 @@ node_modules .node_repl_history # Typescript stuff -build coverage +dist package-lock.json diff --git a/config/tsconfig.base.json b/config/tsconfig.base.json index 9b2c17d..59f69c1 100644 --- a/config/tsconfig.base.json +++ b/config/tsconfig.base.json @@ -4,7 +4,7 @@ "module": "commonjs", "moduleResolution": "node", "removeComments": false, - "outDir": "../build", + "outDir": "../dist", "rootDir": "../src", "declaration": true, "sourceMap": false, diff --git a/config/tsconfig.build.json b/config/tsconfig.build.json index 4bd0edc..ef2c300 100644 --- a/config/tsconfig.build.json +++ b/config/tsconfig.build.json @@ -1,6 +1,3 @@ { "extends": "./tsconfig.base.json", - "compilerOptions": { - "outDir": "../" - } } diff --git a/package.json b/package.json index 26704a1..a1b13b0 100644 --- a/package.json +++ b/package.json @@ -2,10 +2,10 @@ "name": "proc-that", "version": "0.0.0-development", "description": "proc(ess)-that - easy extendable etl tool for nodejs written in typesript", - "main": "index.js", - "typings": "index.d.js", + "main": "dist/index.js", + "typings": "dist/index.d.js", "scripts": { - "clean": "del-cli ./build ./coverage", + "clean": "del-cli ./dist ./coverage", "build": "npm run clean && tsc -p ./config/tsconfig.build.json", "develop": "npm run clean && tsc -p .", "lint": "npm run lint:ts && npm run prettier", @@ -15,9 +15,7 @@ "prettier": "prettier --config .prettierrc.json --list-different \"./**/*.{ts,tsx}\"", "prettier:fix": "prettier --config .prettierrc.json --list-different \"./**/*.{ts,tsx}\" --write", "test": "npm run lint && npm run clean && jest -c ./jest.json", - "test:watch": "npm run clean && jest -c ./jest.json --watch", - "typedoc": "del-cli ./docs && typedoc --ignoreCompilerErrors --out ./docs --mode file --tsconfig ./config/tsconfig.build.json ./src/", - "semantic-release": "semantic-release" + "test:watch": "npm run clean && jest -c ./jest.json --watch" }, "keywords": [ "etl", @@ -42,10 +40,8 @@ "eslint": "^8.30.0", "jest": "^29.3.1", "prettier": "^2.8.1", - "semantic-release": "^19.0.5", "ts-jest": "^29.0.3", "tsutils": "^3.21.0", - "typedoc": "^0.23.23", "typescript": "^4.9.4" }, "dependencies": {