Skip to content

build(deps-dev): bump tsx from 4.23.13 to 4.23.15 (#337) #336

build(deps-dev): bump tsx from 4.23.13 to 4.23.15 (#337)

build(deps-dev): bump tsx from 4.23.13 to 4.23.15 (#337) #336

Workflow file for this run

name: Release
on:
push:
branches: [main]
permissions:
contents: write
pull-requests: write
packages: write
jobs:
release-please:
runs-on: ubuntu-latest
outputs:
release_created: ${{ steps.release.outputs.release_created }}
tag_name: ${{ steps.release.outputs.tag_name }}
steps:
- uses: actions/create-github-app-token@v3
id: app-token
with:
app-id: ${{ vars.RELEASE_APP_ID }}
private-key: ${{ secrets.RELEASE_APP_PRIVATE_KEY }}
- uses: googleapis/release-please-action@v5
id: release
with:
token: ${{ steps.app-token.outputs.token }}
docker:
needs: release-please
if: needs.release-please.outputs.release_created == 'true'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: docker/setup-qemu-action@v4
- uses: docker/setup-buildx-action@v4
- uses: docker/login-action@v4
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Extract version tags
id: version
run: |
VERSION="${{ needs.release-please.outputs.tag_name }}"
VERSION="${VERSION#v}"
echo "version=${VERSION}" >> "$GITHUB_OUTPUT"
echo "minor=${VERSION%.*}" >> "$GITHUB_OUTPUT"
echo "major=${VERSION%%.*}" >> "$GITHUB_OUTPUT"
- uses: docker/metadata-action@v6
id: meta
with:
images: ghcr.io/${{ github.repository }}
tags: |
type=raw,value=${{ steps.version.outputs.version }}
type=raw,value=${{ steps.version.outputs.minor }}
type=raw,value=${{ steps.version.outputs.major }}
type=raw,value=latest
- uses: docker/build-push-action@v7
with:
context: .
platforms: linux/amd64,linux/arm64
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max
npm:
needs: release-please
if: needs.release-please.outputs.release_created == 'true'
runs-on: ubuntu-latest
permissions:
contents: read
id-token: write
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v7
with:
node-version: '24'
cache: 'npm'
registry-url: 'https://registry.npmjs.org'
- run: npm ci
- run: npm run build
- name: Copy changelog to packages
run: |
cp CHANGELOG.md packages/core/CHANGELOG.md
cp CHANGELOG.md packages/cli/CHANGELOG.md
- name: Set release version and pin core dependency
run: |
VERSION="${{ needs.release-please.outputs.tag_name }}"
VERSION="${VERSION#v}"
npm version "$VERSION" --no-git-tag-version --workspace=packages/core
npm version "$VERSION" --no-git-tag-version --workspace=packages/cli
node -e "
const fs = require('fs');
const pkg = JSON.parse(fs.readFileSync('packages/cli/package.json', 'utf8'));
pkg.dependencies['@erode-app/core'] = '$VERSION';
fs.writeFileSync('packages/cli/package.json', JSON.stringify(pkg, null, 2) + '\n');
"
- name: Publish @erode-app/core
run: npm publish --workspace=packages/core --provenance --access public
- name: Publish @erode-app/cli
run: npm publish --workspace=packages/cli --provenance --access public