Skip to content

Commit

Permalink
Turbo publish bug fix (#1103)
Browse files Browse the repository at this point in the history
* Prepublish command removed

* Publish packages with turbo config
  • Loading branch information
0xp3gasus authored Mar 26, 2024
1 parent b9679e0 commit 15a91c8
Show file tree
Hide file tree
Showing 37 changed files with 20 additions and 53 deletions.
9 changes: 2 additions & 7 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,18 +34,13 @@ jobs:
- name: Install dependencies
run: yarn install --frozen-lockfile

- name: Build packages
run: yarn build

- name: Test
run: yarn test

- name: Create release pull request or publish to npm
id: changesets
uses: changesets/action@v1
with:
version: yarn increase-packages
publish: yarn changeset publish
publish: yarn publish-packages

env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
"lint": "turbo run lint",
"update-packages": "yarn changeset",
"increase-packages": "yarn changeset version",
"publish-packages": "turbo run build test --cache-dir=.turbo && yarn increase-packages && yarn changeset publish",
"notification:prepare": "ts-node scripts/notification.ts"
},
"husky": {
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-aggregator/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
"build": "yarn build:pro",
"build:dev": "tsup --env.ENV dev",
"build:pro": "tsup --env.ENV pro",
"prepublishOnly": "yarn run build",
"e2e": "jest --config jest.config.e2e.js",
"test": "jest"
},
Expand Down
3 changes: 1 addition & 2 deletions packages/xchain-arbitrum/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@
"build": "yarn clean && rollup -c",
"test": "jest --passWithNoTests",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build"
"lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0"
},
"publishConfig": {
"access": "public"
Expand Down
3 changes: 1 addition & 2 deletions packages/xchain-avax/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@
"build": "yarn clean && rollup -c",
"test": "jest --passWithNoTests",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build"
"lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0"
},
"publishConfig": {
"access": "public"
Expand Down
3 changes: 1 addition & 2 deletions packages/xchain-binance/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,7 @@
"build": "yarn clean && rollup -c",
"test": "jest",
"compile": "tsc -p tsconfig.build.json",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build"
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0"
},
"devDependencies": {
"@binance-chain/javascript-sdk": "^4.2.0",
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-bitcoin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
"test": "jest",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build",
"postversion": "git push --follow-tags"
},
"devDependencies": {
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-bitcoincash/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
"test": "jest",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__,__mocks__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build",
"postversion": "git push --follow-tags"
},
"dependencies": {
Expand Down
3 changes: 1 addition & 2 deletions packages/xchain-bsc/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@
"build": "yarn clean && rollup -c",
"test": "jest --passWithNoTests",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build"
"lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0"
},
"publishConfig": {
"access": "public"
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-client/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
"clean": "rm -rf .turbo && rm -rf lib",
"build": "yarn clean && rollup -c",
"compile": "tsc -p tsconfig.build.json",
"prepublishOnly": "yarn run build",
"test": "jest --passWithNoTests"
},
"devDependencies": {
Expand Down
3 changes: 1 addition & 2 deletions packages/xchain-cosmos-sdk/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@
"build": "yarn clean && rollup -c",
"test": "jest --passWithNoTests",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build"
"lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0"
},
"publishConfig": {
"access": "public"
Expand Down
3 changes: 1 addition & 2 deletions packages/xchain-cosmos/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@
"build": "yarn clean && rollup -c",
"test": "jest",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build"
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0"
},
"dependencies": {
"@cosmjs/amino": "0.31.1",
Expand Down
3 changes: 1 addition & 2 deletions packages/xchain-crypto/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
"clean": "rm -rf .turbo && rm -rf lib",
"build": "yarn clean && rollup -c",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"test": "jest --coverage",
"prepublishOnly": "yarn build"
"test": "jest --coverage"
},
"repository": {
"type": "git",
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-dash/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
"test": "jest",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build",
"postversion": "git push --follow-tags"
},
"devDependencies": {
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-doge/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
"test": "jest",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build",
"postversion": "git push --follow-tags"
},
"devDependencies": {
Expand Down
3 changes: 1 addition & 2 deletions packages/xchain-ethereum/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@
"build": "yarn clean && rollup -c",
"test": "jest --passWithNoTests",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build"
"lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0"
},
"publishConfig": {
"access": "public"
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-evm-providers/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
"scripts": {
"build": "yarn clean && rollup -c",
"clean": "rm -rf .turbo && rm -rf lib",
"prepublishOnly": "yarn run build",
"e2e": "jest --config jest.config.e2e.js",
"test": "jest --passWithNoTests"
},
Expand Down
3 changes: 1 addition & 2 deletions packages/xchain-evm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,7 @@
"clean": "rm -rf .turbo && rm -rf lib",
"build": "yarn clean && rollup -c",
"test": "jest",
"lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build"
"lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0"
},
"publishConfig": {
"access": "public"
Expand Down
3 changes: 1 addition & 2 deletions packages/xchain-kujira/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@
"build": "yarn clean && rollup -c",
"test": "jest --passWithNoTests",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build"
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0"
},
"dependencies": {
"@cosmjs/amino": "0.31.1",
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-litecoin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
"test": "jest",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"e2e": "jest --config jest.config.e2e.js",
"prepublishOnly": "yarn build",
"postversion": "git push --follow-tags"
},
"devDependencies": {
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-mayachain-amm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
"test": "jest",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build",
"postversion": "git push --follow-tags"
},
"bugs": {
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-mayachain-query/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
"test": "jest",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build",
"postversion": "git push --follow-tags"
},
"devDependencies": {
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-mayachain/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
"test": "jest",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build",
"start:example": "ts-node example/index.ts",
"generate:MayachainMsgs": "./genMsgs.sh"
},
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-mayamidgard-query/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
"test": "jest",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build",
"postversion": "git push --follow-tags"
},
"devDependencies": {
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-mayamidgard/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@
"clean": "rm -rf .turbo && rm -rf lib",
"build": "yarn clean && rollup -c",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn run build",
"test": "jest --passWithNoTests",
"generate:types": "yarn clean:types:midgard && yarn generate:types:midgard",
"generate:types:midgard": "TS_POST_PROCESS_FILE=./node_modules/.bin/prettier openapi-generator-cli generate -i https://midgard.mayachain.info/v2/swagger.json -g typescript-axios -o ./src/generated/midgardApi --generate-alias-as-model --reserved-words-mappings in=in",
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-mayanode/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@
"clean": "rm -rf .turbo && rm -rf lib",
"build": "yarn clean && rollup -c",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build",
"test": "jest --passWithNoTests",
"generate:types": "yarn clean:types:mayanode && yarn generate:types:mayanode",
"generate:types:mayanode": "TS_POST_PROCESS_FILE=./node_modules/.bin/prettier openapi-generator-cli generate -i https://mayanode.mayachain.info/mayachain/doc//openapi.yaml -g typescript-axios -o ./src/generated/mayanodeApi --skip-validate-spec --generate-alias-as-model",
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-midgard-query/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
"test": "jest",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build",
"postversion": "git push --follow-tags"
},
"devDependencies": {
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-midgard/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@
"clean": "rm -rf .turbo && rm -rf lib",
"build": "yarn clean && rollup -c",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn run build",
"test": "jest --passWithNoTests",
"generate:types": "yarn clean:types:midgard && yarn generate:types:midgard",
"generate:types:midgard": "TS_POST_PROCESS_FILE=./node_modules/.bin/prettier openapi-generator-cli generate -i https://midgard.ninerealms.com/v2/swagger.json -g typescript-axios -o ./src/generated/midgardApi --generate-alias-as-model --reserved-words-mappings in=in",
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-thorchain-amm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
"test": "jest",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build",
"postversion": "git push --follow-tags"
},
"bugs": {
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-thorchain-query/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
"test": "jest",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build",
"postversion": "git push --follow-tags"
},
"devDependencies": {
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-thorchain/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
"test": "jest",
"e2e": "jest --config jest.config.e2e.js",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build",
"start:example": "ts-node example/index.ts",
"generate:ThorchainMsgs": "./genMsgs.sh"
},
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-thornode/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@
"clean": "rm -rf .turbo && rm -rf lib",
"build": "yarn clean && rollup -c",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build",
"test": "jest --passWithNoTests",
"generate:types": "yarn clean:types:thornode && yarn generate:types:thornode",
"generate:types:thornode": "TS_POST_PROCESS_FILE=./node_modules/.bin/prettier openapi-generator-cli generate -i https://gitlab.com/thorchain/thornode/-/raw/release-1.128.1/openapi/openapi.yaml -g typescript-axios -o ./src/generated/thornodeApi --skip-validate-spec --generate-alias-as-model",
Expand Down
3 changes: 1 addition & 2 deletions packages/xchain-util/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,7 @@
"clean": "rm -rf .turbo && rm -rf lib",
"build": "yarn clean && rollup -c",
"test": "jest",
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build"
"lint": "eslint \"{src,__tests__}/**/*.ts\" --fix --max-warnings 0"
},
"peerDependencies": {
"bignumber.js": "9.x"
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-utxo-providers/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
"scripts": {
"build": "yarn clean && rollup -c",
"clean": "rm -rf .turbo && rm -rf lib",
"prepublishOnly": "yarn run build",
"e2e": "jest --config jest.config.e2e.js",
"test": "jest "
},
Expand Down
3 changes: 1 addition & 2 deletions packages/xchain-utxo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,7 @@
"scripts": {
"clean": "rm -rf .turbo && rm -rf lib",
"build": "yarn clean && rollup -c",
"lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0",
"prepublishOnly": "yarn build"
"lint": "eslint \"{src,__tests__, __mocks__}/**/*.ts\" --fix --max-warnings 0"
},
"publishConfig": {
"access": "public"
Expand Down
1 change: 0 additions & 1 deletion packages/xchain-wallet/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
"scripts": {
"build": "yarn clean && rollup -c",
"clean": "rm -rf .turbo && rm -rf lib",
"prepublishOnly": "yarn run build",
"e2e": "jest --config jest.config.e2e.js",
"test": "jest"
},
Expand Down
5 changes: 5 additions & 0 deletions turbo.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@
"test/**/*.ts"
]
},
"publish": {
"dependsOn": [
"build"
]
},
"clean": {
"cache": false
}
Expand Down

0 comments on commit 15a91c8

Please sign in to comment.