diff --git a/.github/workflows/akamai-base.yml b/.github/workflows/akamai-base.yml deleted file mode 100644 index e004237f0f..0000000000 --- a/.github/workflows/akamai-base.yml +++ /dev/null @@ -1,24 +0,0 @@ -name: sdk/akamai-base - -on: - push: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' #Do not need to run CI for markdown changes. - pull_request: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' - -jobs: - build-test-akamai: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - - id: shared - name: Shared CI Steps - uses: ./actions/ci - with: - workspace_name: '@launchdarkly/akamai-server-base-sdk' - workspace_path: packages/sdk/akamai-base diff --git a/.github/workflows/akamai-edgekv.yml b/.github/workflows/akamai-edgekv.yml deleted file mode 100644 index d13adfed0d..0000000000 --- a/.github/workflows/akamai-edgekv.yml +++ /dev/null @@ -1,24 +0,0 @@ -name: sdk/akamai-edgekv - -on: - push: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' #Do not need to run CI for markdown changes. - pull_request: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' - -jobs: - build-test-akamai-edgekv: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - - id: shared - name: Shared CI Steps - uses: ./actions/ci - with: - workspace_name: '@launchdarkly/akamai-server-edgekv-sdk' - workspace_path: packages/sdk/akamai-edgekv diff --git a/.github/workflows/akamai-edgeworker-sdk.yml b/.github/workflows/akamai-edgeworker-sdk.yml deleted file mode 100644 index c8fc941cbd..0000000000 --- a/.github/workflows/akamai-edgeworker-sdk.yml +++ /dev/null @@ -1,27 +0,0 @@ -name: shared/akamai-edgeworker-sdk - -on: - push: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' #Do not need to run CI for markdown changes. - pull_request: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' - -jobs: - build-test-akamai-edgeworker-sdk: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16 - registry-url: 'https://registry.npmjs.org' - - id: shared - name: Shared CI Steps - uses: ./actions/ci - with: - workspace_name: '@launchdarkly/akamai-edgeworker-sdk-common' - workspace_path: packages/shared/akamai-edgeworker-sdk diff --git a/.github/workflows/cloudflare.yml b/.github/workflows/cloudflare.yml deleted file mode 100644 index 9501c3ee06..0000000000 --- a/.github/workflows/cloudflare.yml +++ /dev/null @@ -1,24 +0,0 @@ -name: sdk/cloudflare - -on: - push: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' #Do not need to run CI for markdown changes. - pull_request: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' - -jobs: - build-test-cloudflare: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - - id: shared - name: Shared CI Steps - uses: ./actions/ci - with: - workspace_name: '@launchdarkly/cloudflare-server-sdk' - workspace_path: packages/sdk/cloudflare diff --git a/.github/workflows/common.yml b/.github/workflows/common.yml deleted file mode 100644 index bb8faf4604..0000000000 --- a/.github/workflows/common.yml +++ /dev/null @@ -1,27 +0,0 @@ -name: shared/common - -on: - push: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' #Do not need to run CI for markdown changes. - pull_request: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' - -jobs: - build-test-common: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16 - registry-url: 'https://registry.npmjs.org' - - id: shared - name: Shared CI Steps - uses: ./actions/ci - with: - workspace_name: '@launchdarkly/js-sdk-common' - workspace_path: packages/shared/common diff --git a/.github/workflows/lint-pr-title.yml b/.github/workflows/lint-pr-title.yml deleted file mode 100644 index 3518c29c5c..0000000000 --- a/.github/workflows/lint-pr-title.yml +++ /dev/null @@ -1,17 +0,0 @@ -name: Lint PR title - -on: - pull_request_target: - types: - - opened - - edited - - synchronize - -jobs: - main: - name: Verify the PR title matches conventional commit spec. - runs-on: ubuntu-latest - steps: - - uses: amannn/action-semantic-pull-request@v5 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/manual-publish-docs.yml b/.github/workflows/manual-publish-docs.yml index 9380d4e17b..e7f411e630 100644 --- a/.github/workflows/manual-publish-docs.yml +++ b/.github/workflows/manual-publish-docs.yml @@ -7,17 +7,7 @@ on: default: 'packages/shared/common' type: choice options: - - packages/shared/common - - packages/shared/sdk-server - - packages/shared/sdk-server-edge - - packages/shared/akamai-edgeworker-sdk - - packages/sdk/cloudflare - packages/sdk/server-node - - packages/sdk/vercel - - packages/sdk/akamai-base - - packages/sdk/akamai-edgekv - - packages/store/node-server-sdk-redis - - packages/store/node-server-sdk-dynamodb name: Publish Documentation jobs: build-publish: diff --git a/.github/workflows/manual-publish.yml b/.github/workflows/manual-publish.yml index aa7f508c62..9311364bb1 100644 --- a/.github/workflows/manual-publish.yml +++ b/.github/workflows/manual-publish.yml @@ -8,17 +8,7 @@ on: default: 'packages/shared/common' type: choice options: - - packages/shared/common - - packages/shared/sdk-server - - packages/shared/sdk-server-edge - - packages/shared/akamai-edgeworker-sdk - - packages/sdk/cloudflare - packages/sdk/server-node - - packages/sdk/vercel - - packages/sdk/akamai-base - - packages/sdk/akamai-edgekv - - packages/store/node-server-sdk-redis - - packages/store/node-server-sdk-dynamodb prerelease: description: 'Is this a prerelease. If so, then the latest tag will not be updated in npm.' type: boolean diff --git a/.github/workflows/node-dynamodb.yml b/.github/workflows/node-dynamodb.yml deleted file mode 100644 index 4a02ebb66a..0000000000 --- a/.github/workflows/node-dynamodb.yml +++ /dev/null @@ -1,29 +0,0 @@ -name: store/node-server-sdk-dynamodb - -on: - push: - branches: [main, rlamb/implement-dynamodb-store] - paths-ignore: - - '**.md' #Do not need to run CI for markdown changes. - pull_request: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' - -jobs: - build-test-node-dynamo: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16 - registry-url: 'https://registry.npmjs.org' - - run: | - sudo docker run -d -p 8000:8000 amazon/dynamodb-local - - id: shared - name: Shared CI Steps - uses: ./actions/ci - with: - workspace_name: '@launchdarkly/node-server-sdk-dynamodb' - workspace_path: packages/store/node-server-sdk-dynamodb diff --git a/.github/workflows/node-redis.yml b/.github/workflows/node-redis.yml deleted file mode 100644 index c60df70946..0000000000 --- a/.github/workflows/node-redis.yml +++ /dev/null @@ -1,33 +0,0 @@ -name: store/node-server-sdk-redis - -on: - push: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' #Do not need to run CI for markdown changes. - pull_request: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' - -jobs: - build-test-node-redis: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16 - registry-url: 'https://registry.npmjs.org' - # We may want to consider moving this build to a docker container instead of installing it - # in the image. - - run: | - sudo apt-get update - sudo apt-get install redis-server - sudo service redis-server start - - id: shared - name: Shared CI Steps - uses: ./actions/ci - with: - workspace_name: '@launchdarkly/node-server-sdk-redis' - workspace_path: packages/store/node-server-sdk-redis diff --git a/.github/workflows/release-please.yml b/.github/workflows/release-please.yml index 494977f580..147d1ecb97 100644 --- a/.github/workflows/release-please.yml +++ b/.github/workflows/release-please.yml @@ -1,131 +1,21 @@ on: push: branches: - - main + - node-server-sdk-8.x name: release-please jobs: release-please: runs-on: ubuntu-latest outputs: - package-common-released: ${{ steps.release.outputs['packages/shared/common--release_created'] }} - package-sdk-server-released: ${{ steps.release.outputs['packages/shared/sdk-server--release_created'] }} - package-sdk-server-edge-released: ${{ steps.release.outputs['packages/shared/sdk-server-edge--release_created'] }} - package-akamai-edgeworker-sdk-released: ${{ steps.release.outputs['packages/shared/akamai-edgeworker-sdk--release_created'] }} - package-cloudflare-released: ${{ steps.release.outputs['packages/sdk/cloudflare--release_created'] }} package-server-node-released: ${{ steps.release.outputs['packages/sdk/server-node--release_created'] }} - package-vercel-released: ${{ steps.release.outputs['packages/sdk/vercel--release_created'] }} - package-akamai-base-released: ${{ steps.release.outputs['packages/sdk/akamai-base--release_created'] }} - package-akamai-edgekv-released: ${{ steps.release.outputs['packages/sdk/akamai-edgekv--release_created'] }} - package-node-server-sdk-redis-release: ${{ steps.release.outputs['packages/store/node-server-sdk-redis--release_created'] }} - package-node-server-sdk-dynamodb-release: ${{ steps.release.outputs['packages/store/node-server-sdk-dynamodb--release_created'] }} steps: - uses: google-github-actions/release-please-action@v3 id: release with: command: manifest token: ${{secrets.GITHUB_TOKEN}} - default-branch: main - - release-common: - runs-on: ubuntu-latest - needs: ['release-please'] - permissions: - id-token: write - contents: write - if: ${{ needs.release-please.outputs.package-common-released }} - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16.x - registry-url: 'https://registry.npmjs.org' - - id: release-common - name: Full release of packages/shared/common - uses: ./actions/full-release - with: - workspace_path: packages/shared/common - aws_assume_role: ${{ vars.AWS_ROLE_ARN }} - - release-sdk-server: - runs-on: ubuntu-latest - needs: ['release-please'] - permissions: - id-token: write - contents: write - if: ${{ needs.release-please.outputs.package-sdk-server-released }} - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16.x - registry-url: 'https://registry.npmjs.org' - - id: release-common - name: Full release of packages/shared/sdk-server - uses: ./actions/full-release - with: - workspace_path: packages/shared/sdk-server - aws_assume_role: ${{ vars.AWS_ROLE_ARN }} - - release-sdk-server-edge: - runs-on: ubuntu-latest - needs: ['release-please'] - permissions: - id-token: write - contents: write - if: ${{ needs.release-please.outputs.package-sdk-server-edge-released }} - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16.x - registry-url: 'https://registry.npmjs.org' - - id: release-common - name: Full release of packages/shared/sdk-server-edge - uses: ./actions/full-release - with: - workspace_path: packages/shared/sdk-server-edge - aws_assume_role: ${{ vars.AWS_ROLE_ARN }} - - release-akamai-edgeworker-sdk: - runs-on: ubuntu-latest - needs: ['release-please'] - permissions: - id-token: write - contents: write - if: ${{ needs.release-please.outputs.package-akamai-edgeworker-sdk-released }} - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16.x - registry-url: 'https://registry.npmjs.org' - - id: release-common - name: Full release of packages/shared/akamai-edgeworker-sdk - uses: ./actions/full-release - with: - workspace_path: packages/shared/akamai-edgeworker-sdk - aws_assume_role: ${{ vars.AWS_ROLE_ARN }} - - release-cloudflare: - runs-on: ubuntu-latest - needs: ['release-please'] - permissions: - id-token: write - contents: write - if: ${{ needs.release-please.outputs.package-cloudflare-released }} - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16.x - registry-url: 'https://registry.npmjs.org' - - id: release-common - name: Full release of packages/sdk/cloudflare - uses: ./actions/full-release - with: - workspace_path: packages/sdk/cloudflare - aws_assume_role: ${{ vars.AWS_ROLE_ARN }} + default-branch: node-server-sdk-8.x release-server-node: runs-on: ubuntu-latest @@ -146,109 +36,3 @@ jobs: with: workspace_path: packages/sdk/server-node aws_assume_role: ${{ vars.AWS_ROLE_ARN }} - - release-vercel: - runs-on: ubuntu-latest - needs: ['release-please'] - permissions: - id-token: write - contents: write - if: ${{ needs.release-please.outputs.package-vercel-released }} - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16.x - registry-url: 'https://registry.npmjs.org' - - id: release-common - name: Full release of packages/sdk/vercel - uses: ./actions/full-release - with: - workspace_path: packages/sdk/vercel - aws_assume_role: ${{ vars.AWS_ROLE_ARN }} - - release-akamai-base: - runs-on: ubuntu-latest - needs: ['release-please'] - permissions: - id-token: write - contents: write - if: ${{ needs.release-please.outputs.package-akamai-base-released }} - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16.x - registry-url: 'https://registry.npmjs.org' - - id: release-common - name: Full release of packages/sdk/akamai-base - uses: ./actions/full-release - with: - workspace_path: packages/sdk/akamai-base - aws_assume_role: ${{ vars.AWS_ROLE_ARN }} - - release-akamai-edgekv: - runs-on: ubuntu-latest - needs: ['release-please'] - permissions: - id-token: write - contents: write - if: ${{ needs.release-please.outputs.package-akamai-edgekv-released }} - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16.x - registry-url: 'https://registry.npmjs.org' - - id: release-common - name: Full release of packages/sdk/akamai-edgekv - uses: ./actions/full-release - with: - workspace_path: packages/sdk/akamai-edgekv - aws_assume_role: ${{ vars.AWS_ROLE_ARN }} - - release-node-server-sdk-redis: - runs-on: ubuntu-latest - needs: ['release-please'] - permissions: - id-token: write - contents: write - if: ${{ needs.release-please.outputs.package-node-server-sdk-redis-release }} - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16.x - registry-url: 'https://registry.npmjs.org' - - run: | - sudo apt-get update - sudo apt-get install redis-server - sudo service redis-server start - - id: release-common - name: Full release of packages/store/node-server-sdk-redis - uses: ./actions/full-release - with: - workspace_path: packages/store/node-server-sdk-redis - aws_assume_role: ${{ vars.AWS_ROLE_ARN }} - - release-node-server-sdk-dynamodb: - runs-on: ubuntu-latest - needs: ['release-please'] - permissions: - id-token: write - contents: write - if: ${{ needs.release-please.outputs.package-node-server-sdk-dynamodb-release }} - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16.x - registry-url: 'https://registry.npmjs.org' - - run: | - sudo docker run -d -p 8000:8000 amazon/dynamodb-local - - id: release-common - name: Full release of packages/store/node-server-sdk-dynamodb - uses: ./actions/full-release - with: - workspace_path: packages/store/node-server-sdk-dynamodb - aws_assume_role: ${{ vars.AWS_ROLE_ARN }} diff --git a/.github/workflows/sdk-server-edge.yml b/.github/workflows/sdk-server-edge.yml deleted file mode 100644 index 3ef228ba45..0000000000 --- a/.github/workflows/sdk-server-edge.yml +++ /dev/null @@ -1,27 +0,0 @@ -name: shared/sdk-server-edge - -on: - push: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' #Do not need to run CI for markdown changes. - pull_request: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' - -jobs: - build-test-sdk-server: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16 - registry-url: 'https://registry.npmjs.org' - - id: shared - name: Shared CI Steps - uses: ./actions/ci - with: - workspace_name: '@launchdarkly/js-server-sdk-common-edge' - workspace_path: packages/shared/sdk-server-edge diff --git a/.github/workflows/sdk-server.yml b/.github/workflows/sdk-server.yml deleted file mode 100644 index 2b975763f5..0000000000 --- a/.github/workflows/sdk-server.yml +++ /dev/null @@ -1,27 +0,0 @@ -name: shared/sdk-server - -on: - push: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' #Do not need to run CI for markdown changes. - pull_request: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' - -jobs: - build-test-sdk-server: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - with: - node-version: 16 - registry-url: 'https://registry.npmjs.org' - - id: shared - name: Shared CI Steps - uses: ./actions/ci - with: - workspace_name: '@launchdarkly/js-server-sdk-common' - workspace_path: packages/shared/sdk-server diff --git a/.github/workflows/server-node.yml b/.github/workflows/server-node.yml index 7ccaec76de..02ae2defd4 100644 --- a/.github/workflows/server-node.yml +++ b/.github/workflows/server-node.yml @@ -2,11 +2,11 @@ name: sdk/server-node on: push: - branches: [main, 'feat/**'] + branches: [node-server-sdk-8.x] paths-ignore: - '**.md' #Do not need to run CI for markdown changes. pull_request: - branches: [main, 'feat/**'] + branches: [node-server-sdk-8.x] paths-ignore: - '**.md' diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml deleted file mode 100644 index 2ac9e7b528..0000000000 --- a/.github/workflows/stale.yml +++ /dev/null @@ -1,14 +0,0 @@ -name: 'Close stale issues and PRs' -on: - schedule: - - cron: '30 1 * * *' - -jobs: - stale: - runs-on: ubuntu-latest - steps: - - uses: actions/stale@v7 - with: - stale-issue-message: 'This issue is stale because it has been open for 90 days without activity. Remove the stale label or comment, or this will be closed in 14 days.' - days-before-stale: 90 - days-before-close: 14 diff --git a/.github/workflows/vercel.yml b/.github/workflows/vercel.yml deleted file mode 100644 index f633491336..0000000000 --- a/.github/workflows/vercel.yml +++ /dev/null @@ -1,24 +0,0 @@ -name: sdk/vercel - -on: - push: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' #Do not need to run CI for markdown changes. - pull_request: - branches: [main, 'feat/**'] - paths-ignore: - - '**.md' - -jobs: - build-test-vercel: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-node@v3 - - id: shared - name: Shared CI Steps - uses: ./actions/ci - with: - workspace_name: '@launchdarkly/vercel-server-sdk' - workspace_path: packages/sdk/vercel diff --git a/README.md b/README.md index f069584734..e6240f440b 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,9 @@ # LaunchDarkly monorepo for JavaScript SDKs. +> [!WARNING] +> This branch is for maintenance of the `@launchdarkly/node-server-sdk` version 8.x. +> Only 8.x releases will be created from this branch. If releases of shared packages are required, then they will require their own maintenance branches. + This repository contains LaunchDarkly SDK packages which are designed for execution in JavaScript environments. This includes shared libraries, used by SDKs and other tools, as well as SDKs. diff --git a/release-please-config.json b/release-please-config.json index 63cc824091..67cbab3530 100644 --- a/release-please-config.json +++ b/release-please-config.json @@ -1,24 +1,6 @@ { "packages": { - "packages/shared/common": {}, - "packages/shared/sdk-server": {}, - "packages/shared/sdk-server-edge": {}, - "packages/shared/akamai-edgeworker-sdk": { - "bump-minor-pre-major": true - }, - "packages/sdk/server-node": {}, - "packages/sdk/cloudflare": {}, - "packages/sdk/vercel": { - "extra-files": ["src/createPlatformInfo.ts"] - }, - "packages/sdk/akamai-base": { - "extra-files": ["src/index.ts"] - }, - "packages/sdk/akamai-edgekv": { - "extra-files": ["src/index.ts"] - }, - "packages/store/node-server-sdk-dynamodb": {}, - "packages/store/node-server-sdk-redis": {} + "packages/sdk/server-node": {} }, "plugins": ["node-workspace"] } diff --git a/scripts/publish.sh b/scripts/publish.sh index 597e964da0..edf2980f08 100755 --- a/scripts/publish.sh +++ b/scripts/publish.sh @@ -7,6 +7,8 @@ else echo "Publishing with prerelease tag." yarn workspace $WORKSPACE npm publish --tag prerelease || { echo "npm publish failed" >&2; exit 1; } else - yarn workspace $WORKSPACE npm publish || { echo "npm publish failed" >&2; exit 1; } + # Using a maintenance tag prevents this release from getting tagged with "latest". + echo "Publishing with maintenance tag." + yarn workspace $WORKSPACE npm publish --tag maintenance || { echo "npm publish failed" >&2; exit 1; } fi fi