Skip to content

Commit 698a401

Browse files
authored
Pre-release CI fixes (#105)
* version 1.0.2 * wip * adds ci-test to hooks * clean up * renames branch name
1 parent 258d068 commit 698a401

File tree

11 files changed

+55
-40
lines changed

11 files changed

+55
-40
lines changed

.github/workflows/node.js.yml

Lines changed: 45 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -9,48 +9,47 @@ on:
99
types:
1010
- created
1111

12+
env:
13+
TURBO_API: 'http://127.0.0.1:9080'
14+
TURBO_TOKEN: ${{ secrets.TURBO_SERVER_TOKEN }}
15+
TURBO_TEAM: ${{ github.repository_owner }}
16+
1217
jobs:
1318
build:
1419
runs-on: ubuntu-latest
15-
env:
16-
TURBO_API: 'http://127.0.0.1:9080'
17-
TURBO_TOKEN: ${{ secrets.TURBO_SERVER_TOKEN }}
18-
TURBO_TEAM: ${{ github.repository_owner }}
20+
permissions:
21+
actions: read
1922

2023
steps:
2124
- uses: actions/checkout@v3
2225
- name: Use Node.js
2326
uses: actions/setup-node@v3
2427
with:
25-
node-version: "18.x"
26-
27-
registry-url: "https://registry.npmjs.org"
28+
node-version: '16'
2829

2930
- name: Cache dependencies
3031
id: cache
3132
uses: actions/cache@v3
3233
with:
33-
path: "**/node_modules"
34+
path: '**/node_modules'
3435
key: ${{ runner.os }}-${{ hashFiles('**/yarn.lock') }}
3536

3637
- name: Install dependencies
3738
if: steps.cache.outputs.cache-hit != 'true'
3839
run: yarn install --immutable
3940

40-
- name: Setup local cache server for Turborepo
41+
- name: Setup a local cache server for Turborepo
4142
uses: felixmosh/turborepo-gh-artifacts@v2
4243
with:
4344
repo-token: ${{ secrets.GITHUB_TOKEN }}
44-
server-token: ${{ secrets.TURBO_SERVER_TOKEN }}
45+
server-token: ${{ env.TURBO_TOKEN }}
4546

46-
- run: yarn verify
47-
- run: yarn turbo build --color --concurrency=5
48-
- name: Upload Artifacts
49-
uses: actions/upload-artifact@v3
50-
with:
51-
name: packages
52-
path: |
53-
packages/**/dist
47+
48+
- name: Run lint, type checks and tests
49+
run: yarn verify
50+
51+
- name: Run build
52+
run: yarn turbo build --color --concurrency=5
5453

5554
pre_release:
5655
runs-on: ubuntu-latest
@@ -61,16 +60,17 @@ jobs:
6160

6261
steps:
6362
- uses: actions/checkout@v3
64-
- name: Download Artifacts
65-
uses: actions/download-artifact@v2
6663
- name: Use Node.js
6764
uses: actions/setup-node@v3
65+
with:
66+
node-version: '16'
67+
registry-url: "https://registry.npmjs.org"
6868

6969
- name: Cache dependencies
7070
id: cache
7171
uses: actions/cache@v3
7272
with:
73-
path: "**/node_modules"
73+
path: '**/node_modules'
7474
key: ${{ runner.os }}-${{ hashFiles('**/yarn.lock') }}
7575

7676
- name: Install dependencies
@@ -81,13 +81,13 @@ jobs:
8181
uses: felixmosh/turborepo-gh-artifacts@v2
8282
with:
8383
repo-token: ${{ secrets.GITHUB_TOKEN }}
84-
server-token: ${{ secrets.TURBO_SERVER_TOKEN }}
84+
server-token: ${{ env.TURBO_TOKEN }}
8585

8686
- name: Version
87-
run: yarn lerna version "$(node -e "console.log(require('semver').inc(require('./lerna.json').version, 'patch'))")-pre.${{ github.run_number }}" --yes
87+
run: yarn lerna version "$(node -e "console.log(require('semver').inc(require('./lerna.json').version, 'patch'))")-pre.${{ github.run_number }}" --no-git-tag-version --no-push --yes
8888

8989
- name: Build
90-
run: yarn turbo run build --color --concurrency=5
90+
run: yarn turbo build --color --concurrency=5
9191

9292
- run: git config user.email "<>" && git config user.name "UgandaEMR CI"
9393
- run: git add . && git commit -m "Prerelease version" --no-verify
@@ -97,6 +97,14 @@ jobs:
9797
env:
9898
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
9999

100+
- name: Upload build artifacts
101+
uses: actions/upload-artifact@v3
102+
with:
103+
name: packages
104+
path: |
105+
packages/**/dist
106+
107+
100108
release:
101109
runs-on: ubuntu-latest
102110

@@ -106,13 +114,11 @@ jobs:
106114

107115
steps:
108116
- uses: actions/checkout@v3
109-
- name: Download Artifacts
110-
uses: actions/download-artifact@v3
111117
- name: Use Node.js
112118
uses: actions/setup-node@v3
113119
with:
114-
node-version: "18.x"
115-
registry-url: 'https://registry.npmjs.org'
120+
node-version: '16'
121+
registry-url: "https://registry.npmjs.org"
116122

117123
- name: Cache dependencies
118124
id: cache
@@ -125,7 +131,16 @@ jobs:
125131
if: steps.cache.outputs.cache-hit != 'true'
126132
run: yarn install --immutable
127133

128-
- run: yarn turbo run build --color
129-
- run: yarn run ci:publish
134+
- name: Setup local cache server for Turborepo
135+
uses: felixmosh/turborepo-gh-artifacts@v2
136+
with:
137+
repo-token: ${{ secrets.GITHUB_TOKEN }}
138+
server-token: ${{ env.TURBO_TOKEN }}
139+
140+
- name: Build
141+
run: yarn turbo build --color --concurrency=5
142+
143+
- name: Publish
144+
run: yarn run ci:publish
130145
env:
131146
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}

lerna.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
],
55
"npmClient": "yarn",
66
"useWorkspaces": true,
7-
"version": "1.0.1",
7+
"version": "1.0.2",
88
"command": {
99
"publish": {
1010
"verifyAccess": false

packages/esm-family-health-app/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@ugandaemr/esm-family-health-app",
3-
"version": "1.0.1",
3+
"version": "1.0.2",
44
"license": "MPL-2.0",
55
"description": "Family health microfrontend for UgandaEMR",
66
"browser": "dist/esm-family-health-app.js",

packages/esm-hiv-app/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@ugandaemr/esm-hiv-app",
3-
"version": "1.0.1",
3+
"version": "1.0.2",
44
"license": "MPL-2.0",
55
"description": "HIV microfrontend for UgandaEMR",
66
"browser": "dist/esm-hiv-app.js",

packages/esm-ipd-app/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@ugandaemr/esm-inpatient-app",
3-
"version": "1.0.1",
3+
"version": "1.0.2",
44
"license": "MPL-2.0",
55
"description": "Inpatient department microfrontend for UgandaEMR",
66
"browser": "dist/esm-inpatient-app.js",

packages/esm-outpatient-app/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@ugandaemr/esm-outpatient-app",
3-
"version": "1.0.1",
3+
"version": "1.0.2",
44
"license": "MPL-2.0",
55
"description": "Outpatient microfrontend for UgandaEMR",
66
"browser": "dist/esm-outpatient-app.js",

packages/esm-patient-queues-app/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@ugandaemr/esm-patient-queues-app",
3-
"version": "1.0.1",
3+
"version": "1.0.2",
44
"license": "MPL-2.0",
55
"description": "Patient queues microfrontend for UgandaEMR",
66
"browser": "dist/esm-patient-queues-app.js",

packages/esm-radiology-app/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@ugandaemr/esm-radiology-app",
3-
"version": "1.0.1",
3+
"version": "1.0.2",
44
"license": "MPL-2.0",
55
"description": "Radiology microfrontend for UgandaEMR",
66
"browser": "dist/esm-radiology-app.js",

packages/esm-tb-app/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@ugandaemr/esm-tb-app",
3-
"version": "1.0.1",
3+
"version": "1.0.2",
44
"license": "MPL-2.0",
55
"description": "tb microfrontend for UgandaEMR",
66
"browser": "dist/esm-tb-app.js",

packages/esm-theatre-app/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@ugandaemr/esm-theatre-app",
3-
"version": "1.0.1",
3+
"version": "1.0.2",
44
"license": "MPL-2.0",
55
"description": "Theatre microfrontend for UgandaEMR",
66
"browser": "dist/esm-theatre-app.js",

0 commit comments

Comments
 (0)