Skip to content
This repository has been archived by the owner on Jan 10, 2024. It is now read-only.

fix: add changeset release workflow #3

Merged
merged 8 commits into from
Feb 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions .changeset/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Changesets

Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works
with multi-package repos, or single-package repos to help you version and publish your code. You can
find the full documentation for it [in our repository](https://github.com/changesets/changesets)

We have a quick list of common questions to get you started engaging with this project in
[our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md)
11 changes: 11 additions & 0 deletions .changeset/config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"$schema": "https://unpkg.com/@changesets/config@2.3.0/schema.json",
"changelog": "@changesets/cli/changelog",
"commit": false,
"fixed": [],
"linked": [],
"access": "restricted",
"baseBranch": "main",
"updateInternalDependencies": "patch",
"ignore": []
}
5 changes: 5 additions & 0 deletions .changeset/grumpy-humans-sip.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"oidc-client-ts": minor
---

add dpop feature
3 changes: 3 additions & 0 deletions .eslintrc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,9 @@ overrides:
"@typescript-eslint/require-await": "off"
"@typescript-eslint/no-unsafe-argument": "off"
"@typescript-eslint/no-unsafe-assignment": "off"
"@typescript-eslint/no-explicit-any": "off"
"@typescript-eslint/no-unsafe-member-access": "off"

- files: src/**/*
env:
node: false
Expand Down
71 changes: 53 additions & 18 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,30 +1,65 @@
name: Release
on:
release:
types: [created]
push:
branches:
- main
workflow_dispatch:

env:
CI: true
REGISTRY: ghcr.io

permissions:
contents: write
pull-requests: write
packages: write

jobs:
publish:
release:
name: Release
runs-on: ubuntu-latest
outputs:
published: ${{ steps.changesets.outputs.published == 'true' }}

# The published packages output from the changsets action is a stringified JSON array.
# For example: '[{"name":"@labshare/auth","version":"6.6.0"},{"name":"@labshare/auth-ui","version":"3.3.1"}]'.
publishedPackages: ${{ steps.changesets.outputs.publishedPackages }}

strategy:
matrix:
node-version: [18.x]

steps:
- uses: actions/checkout@v3
# Setup .npmrc file to publish to npm
- uses: actions/setup-node@v3
with:
node-version: 16.x
cache: npm
registry-url: https://registry.npmjs.org
- name: Checkout
uses: actions/checkout@v3

- run: npm ci
- run: npm publish
- name: Configure CI Github User
run: |
git config --global user.name 'LabShare'
git config --global user.email 'LabShare@labshare.org'
git remote set-url origin https://$GITHUB_ACTOR:$GH_TOKEN@github.com/ncats/auth-monorepo
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
GH_TOKEN: ${{ secrets.GH_TOKEN }}

- run: npm install
with:
npm-token: ${{secrets.NPM_INSTALL_TOKEN}}

- run: npm run typedoc
# Changesets action reuses the .npmrc if it already exists. In this case, we
# need to change to an NPM token with write access.
- run: rm ~/.npmrc
shell: "bash"

- name: Deploy pages
uses: peaceiris/actions-gh-pages@v3
- name: create and publish versions
id: changesets
uses: changesets/action@v1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs/pages
commit: "chore: update versions"
title: "chore: update versions"
publish: npm ci:publish
setupGitUser: false
env:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }}


6 changes: 4 additions & 2 deletions api-extractor.json
Original file line number Diff line number Diff line change
Expand Up @@ -336,8 +336,10 @@
// Completely disable the "ae-extra-release-tag" validation
"logLevel": "none",
"addToApiReportFile": false
}

},
"ae-missing-release-tag": {
"logLevel": "none"
}
// "ae-extra-release-tag": {
// "logLevel": "warning",
// "addToApiReportFile": true
Expand Down
3 changes: 0 additions & 3 deletions docs/oidc-client-ts.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -1121,9 +1121,6 @@ export type UserSignedOutCallback = () => Promise<void> | void;
// @public (undocumented)
export type UserUnloadedCallback = () => Promise<void> | void;

// @public (undocumented)
export const Version: string;

// @public (undocumented)
export class WebStorageStateStore implements StateStore {
constructor({ prefix, store, }?: {
Expand Down
11 changes: 4 additions & 7 deletions jest.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,10 @@ export default {
testEnvironment: "jsdom",
collectCoverage,
coverageReporters: collectCoverage ? ["lcov"] : ["lcov", "text"],
extensionsToTreatAsEsm: ['.ts'],
preset: 'ts-jest/presets/default-esm',
transform: {
"^.+\\.tsx?$": [
"ts-jest",
{
// skip ts-jest type checking, incremental compilation with tsc is much faster
isolatedModules: true,
},
],
'^.+\\.(ts|tsx)?$': ['ts-jest', { useESM: true }],

},
};
Loading