diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index a3173e7..1dae88a 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -9,13 +9,23 @@ jobs: - uses: actions/checkout@v1 - uses: actions/setup-node@v1 with: - node-version: 14 - - run: yarn - - run: yarn build - - run: yarn test + node-version: 20 + - name: Install dependencies + run: yarn install + + - name: Build package + run: | + cd packages/repluggable + yarn build + + - name: Run tests + run: | + cd packages/repluggable + yarn test - name: Bump version run: | + cd packages/repluggable git reset --hard echo yarn version "0.0.0-pr$PR_ID.$BUILD_NUMBER" yarn version "0.0.0-pr$PR_ID.$BUILD_NUMBER" @@ -30,6 +40,7 @@ jobs: - name: npm publish run: | + cd packages/repluggable echo PR package tag is [pr$PR_ID.$BUILD_NUMBER] npm config set //registry.npmjs.org/:_authToken=$NPM_AUTH_TOKEN npm publish --tag "pr$PR_ID.$BUILD_NUMBER" diff --git a/package.json b/package.json index 3ab0165..348045f 100644 --- a/package.json +++ b/package.json @@ -1,40 +1,43 @@ { - "name": "repluggable-monorepo", - "version": "1.0.0", - "license": "MIT", - "description": "Allows composition of a React-with-Redux application entirely from a list of pluggable packages", - "author": { - "name": "Wix.com", - "email": "responsive-feds@wix.com" - }, - "repository": { - "type": "git", - "url": "https://github.com/wix/repluggable" - }, - "scripts": { - "start": "webpack-dev-server --hot --config webpack.local.config.js", - "build": "rm -rf dist && yarn build-cjs && yarn build-es && yarn build-bundle-dev && yarn build-bundle-prod", - "build-cjs": "tsc --outDir dist --module commonjs", - "build-es": "tsc --outDir dist/es --module esNext", - "build-bundle-dev": "webpack --config webpack.dev.config.js", - "build-bundle-prod": "webpack --config webpack.prod.config.js", - "test": "jest --coverage", - "posttest": "tslint --project .", - "lintfix": "tslint --fix --project ." - }, - "resolutions": { - "node-forge": "^1.0.0" - }, - "husky": { - "hooks": { - "pre-commit": "lint-staged" - } - }, - "lint-staged": { - "(src|test|testKit)/**/*.{ts,tsx}": [ - "tslint --project . --fix" - ] - }, - "packageManager": "yarn@4.6.0" - } - \ No newline at end of file + "name": "repluggable-monorepo", + "version": "1.0.0", + "license": "MIT", + "description": "Allows composition of a React-with-Redux application entirely from a list of pluggable packages", + "author": { + "name": "Wix.com", + "email": "responsive-feds@wix.com" + }, + "repository": { + "type": "git", + "url": "https://github.com/wix/repluggable" + }, + "workspaces": [ + "packages/*" + ], + "scripts": { + "start": "yarn workspace repluggable start", + "build": "yarn workspace repluggable build", + "build-cjs": "yarn workspace repluggable build-cjs", + "build-es": "yarn workspace repluggable build-es", + "build-bundle-dev": "yarn workspace repluggable build-bundle-dev", + "build-bundle-prod": "yarn workspace repluggable build-bundle-prod", + "test": "yarn workspace repluggable test", + "posttest": "yarn workspace repluggable posttest", + "lintfix": "yarn workspace repluggable lintfix" + }, + "resolutions": { + "node-forge": "^1.0.0" + }, + "husky": { + "hooks": { + "pre-commit": "lint-staged" + } + }, + "lint-staged": { + "(src|test|testKit)/**/*.{ts,tsx}": [ + "tslint --project . --fix" + ] + }, + "packageManager": "yarn@4.6.0" +} +