Skip to content
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
85 changes: 0 additions & 85 deletions .github/workflows/node.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -664,91 +664,6 @@ jobs:
publish_dir: ./packages/documentation/build
force_orphan: true

release-libs:
name: Release Lib
runs-on: ubuntu-latest
timeout-minutes: 15

# only run for tags
if: contains(github.ref, 'refs/tags/')

needs:
- test-packages
# core must be published first
- build-core

steps:
- uses: actions/checkout@v5
with:
persist-credentials: false
- name: Use Node.js
uses: actions/setup-node@v6
with:
node-version-file: ".node-version"
- name: Prepare Environment # have to run this first to make sure the semver lib is available
run: |
corepack enable

yarn config set cacheFolder /home/runner/release-libs-cache

cd packages
yarn install
env:
CI: true
- name: Check release is desired
id: do-publish
run: |
if [ -z "${{ secrets.NPM_TOKEN }}" ]; then
echo "No Token"
else
# make dependencies of `determine-npm-tag` available
yarn install --mode=skip-build

cd packages
PACKAGE_NAME="@sofie-automation/shared-lib"
PUBLISHED_VERSION=$(yarn npm info --json $PACKAGE_NAME | jq -c '.version' -r)
THIS_VERSION=$(node -p "require('./lerna.json').version")
NPM_TAG=$(node ../scripts/determine-npm-tag.js $PUBLISHED_VERSION $THIS_VERSION)

echo "Publishing $NPM_TAG"
echo "tag=$NPM_TAG" >> $GITHUB_OUTPUT

fi
- name: Build
if: ${{ steps.do-publish.outputs.tag }}
run: |
cd packages
yarn build
env:
CI: true
- name: Build OpenAPI client library
if: ${{ steps.do-publish.outputs.tag }}
run: |
cd packages/openapi
yarn build
env:
CI: true
- name: Modify dependencies to use npm packages
run: node scripts/prepublish.js
- name: Publish to NPM
if: ${{ steps.do-publish.outputs.tag }}
run: |
echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" >> ~/.npmrc

# hack as it can sometimes have unexpected changes
git checkout .yarnrc.yml

cd packages
git checkout .yarnrc.yml

yarn lerna publish from-package --tag-version-prefix='' --dist-tag ${{ steps.do-publish.outputs.tag }} --yes --no-verify-access

NEW_VERSION=$(node -p "require('./package.json').version")
echo "version=$NEW_VERSION" >> $GITHUB_OUTPUT
echo "**Published:** $NEW_VERSION" >> $GITHUB_STEP_SUMMARY
env:
CI: true

check-for-multiple-library-versions:
name: Check for multiple library versions
runs-on: ubuntu-latest
Expand Down
164 changes: 0 additions & 164 deletions .github/workflows/prerelease-libs.yml

This file was deleted.

Loading
Loading