Skip to content

Commit 78d013f

Browse files
committed
ci: fix building before linting/testing
1 parent 21d61ca commit 78d013f

File tree

3 files changed

+8
-30
lines changed

3 files changed

+8
-30
lines changed

.github/workflows/publish-dev.yml

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -36,29 +36,7 @@ jobs:
3636
cache: 'yarn'
3737
cache-dependency-path: yarn.lock
3838

39-
- name: Check previous released version
40-
id: pre-release
41-
run: |
42-
if [[ $(npm view ${{ matrix.package }}@dev version | grep -e "$(jq --raw-output '.version' packages/${{ matrix.folder }}/package.json)\..*-$(git rev-parse --short HEAD)") ]]; \
43-
then echo '::set-output name=release::false'; \
44-
else echo '::set-output name=release::true'; fi
45-
46-
- name: Install dependencies
47-
if: steps.pre-release.outputs.release == 'true'
48-
run: yarn --immutable
49-
50-
- name: Build dependencies
51-
if: steps.pre-release.outputs.release == 'true'
52-
run: yarn build
53-
54-
- name: Deprecate old versions
55-
if: steps.pre-release.outputs.release == 'true'
56-
run: npm deprecate ${{ matrix.package }}@"~$(jq --raw-output '.version' packages/${{ matrix.folder }}/package.json)" "no longer supported" || true
57-
env:
58-
NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }}
59-
6039
- name: Publish
61-
if: steps.pre-release.outputs.release == 'true'
6240
run: |
6341
yarn workspace ${{ matrix.package }} release --preid "dev.$(date +%s)-$(git rev-parse --short HEAD)"
6442
yarn workspace ${{ matrix.package }} npm publish --tag dev || true

.github/workflows/test.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,9 @@ jobs:
1818
- name: Install dependencies
1919
run: yarn --immutable
2020

21+
- name: Build dependencies
22+
run: yarn build
23+
2124
- name: ESLint
2225
run: yarn lint
2326

@@ -27,6 +30,3 @@ jobs:
2730
- name: Upload Coverage
2831
uses: ./packages/actions/src/uploadCoverage
2932
if: github.repository_owner == 'discordjs'
30-
31-
- name: Build
32-
run: yarn build

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
"description": "A powerful library for interacting with the Discord API",
55
"private": true,
66
"scripts": {
7-
"build": "yarn workspaces foreach --topological run build",
8-
"test": "yarn workspaces foreach --topological run test",
9-
"lint": "yarn workspaces foreach --topological run lint",
10-
"format": "yarn workspaces foreach --topological run format",
7+
"build": "yarn workspaces foreach --parallel --topological run build",
8+
"test": "yarn workspaces foreach --parallel --topological run test",
9+
"lint": "yarn workspaces foreach --parallel --topological run lint",
10+
"format": "yarn workspaces foreach --parallel --topological run format",
1111
"fmt": "yarn format",
1212
"postinstall": "is-ci || husky install",
13-
"docs": "yarn workspaces foreach --topological run docs",
13+
"docs": "yarn workspaces foreach --parallel --topological run docs",
1414
"update": "yarn upgrade-interactive"
1515
},
1616
"contributors": [

0 commit comments

Comments
 (0)