Skip to content

Commit e3be448

Browse files
authored
fix lib build to follow the utils dual output pattern, fixes package.… (#43)
* fix lib build to follow the utils dual output pattern, fixes package.json to include proper exports mapping, adds github registry publishing config * fix workflows * syncpack * lockfile * search client * lockfile
1 parent c817322 commit e3be448

20 files changed

Lines changed: 144 additions & 73 deletions

.github/workflows/ci.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ jobs:
1616
test:
1717
name: checks
1818
runs-on: ubuntu-latest
19+
permissions:
20+
contents: read
21+
packages: read
1922
strategy:
2023
fail-fast: false
2124
matrix:
@@ -30,7 +33,10 @@ jobs:
3033
with:
3134
node-version-file: .nvmrc
3235
cache: npm
36+
- run: echo '//npm.pkg.github.com/:_authToken=${NODE_AUTH_TOKEN}' >> ~/.npmrc
3337
- run: npm ci
38+
env:
39+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3440
- run: npm run build
3541
- run: npm run ci
3642
working-directory: packages/${{ matrix.module }}

.github/workflows/lint.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@ jobs:
2626
spelling:
2727
name: spelling
2828
runs-on: ubuntu-latest
29+
permissions:
30+
contents: read
31+
packages: read
2932
env:
3033
CI: true
3134
steps:
@@ -36,11 +39,17 @@ jobs:
3639
with:
3740
node-version-file: .nvmrc
3841
cache: npm
42+
- run: echo '//npm.pkg.github.com/:_authToken=${NODE_AUTH_TOKEN}' >> ~/.npmrc
3943
- run: npm ci
44+
env:
45+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4046
- run: npm run ci:spelling
4147
syncpack:
4248
name: versions
4349
runs-on: ubuntu-latest
50+
permissions:
51+
contents: read
52+
packages: read
4453
env:
4554
CI: true
4655
steps:
@@ -51,5 +60,8 @@ jobs:
5160
with:
5261
node-version-file: .nvmrc
5362
cache: npm
63+
- run: echo '//npm.pkg.github.com/:_authToken=${NODE_AUTH_TOKEN}' >> ~/.npmrc
5464
- run: npm ci
65+
env:
66+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5567
- run: npm run ci:versions

.github/workflows/sbom-pr-check.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ permissions:
99
jobs:
1010
check:
1111
runs-on: ubuntu-latest
12+
permissions:
13+
contents: read
14+
packages: read
1215
steps:
1316
- uses: actions/checkout@v4
1417
with:
@@ -19,7 +22,10 @@ jobs:
1922
node-version-file: .nvmrc
2023
cache: npm
2124

25+
- run: echo '//npm.pkg.github.com/:_authToken=${NODE_AUTH_TOKEN}' >> ~/.npmrc
2226
- run: npm ci
27+
env:
28+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
2329
- run: npm sbom --sbom-format=cyclonedx > /tmp/head-sbom.json
2430

2531
- name: Generate base SBOM

.github/workflows/sbom.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,9 @@ permissions:
2525
jobs:
2626
emit:
2727
runs-on: ubuntu-latest
28+
permissions:
29+
contents: read
30+
packages: read
2831
env:
2932
INVENTORY_REF: ${{ github.event.inputs.ref || 'main' }}
3033
steps:
@@ -38,7 +41,10 @@ jobs:
3841
node-version-file: .nvmrc
3942
cache: npm
4043

44+
- run: echo '//npm.pkg.github.com/:_authToken=${NODE_AUTH_TOKEN}' >> ~/.npmrc
4145
- run: npm ci
46+
env:
47+
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4248
- run: npm sbom --sbom-format=cyclonedx > /tmp/sbom.json
4349

4450
# birder is private and this repo is public, so the run's GITHUB_TOKEN

.npmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@openstax:registry=https://npm.pkg.github.com

package-lock.json

Lines changed: 56 additions & 29 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

packages/frontend/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "@project/frontend",
33
"version": "0.1.0",
44
"dependencies": {
5-
"@openstax/orn-locator": "^1.4.1",
5+
"@openstax/orn-locator": "^1.5.0",
66
"@openstax/ts-utils": "1.50.2",
77
"@openstax/ui-components": "github:openstax/ui-components#1.23.0",
88
"@testing-library/jest-dom": "^6.4.7",

packages/lambda/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
"name": "@project/lambdas",
33
"version": "1.0.0",
44
"dependencies": {
5-
"@openstax/open-search-client": "^0.1.0-build.8",
6-
"@openstax/orn-locator": "^1.4.1",
5+
"@openstax/open-search-client": "^0.1.1",
6+
"@openstax/orn-locator": "^1.5.0",
77
"@openstax/ts-utils": "1.50.2",
88
"aws-xray-sdk": "^3.6.0",
99
"body-parser": "^1.19.2",

0 commit comments

Comments
 (0)