Skip to content

Version Packages

Version Packages #861

Workflow file for this run

name: Release Gate
on:
pull_request:
types: [opened, synchronize]
paths-ignore:
- '**/*.md'
- '.changeset/**'
workflow_dispatch:
concurrency:
group: release-gate-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
permissions:
contents: read
jobs:
release-gate:
name: Release Gate (ubuntu-latest, 24)
runs-on: ubuntu-latest
timeout-minutes: 30
env:
HUSKY: 0
steps:
- name: Checkout Repo
uses: actions/checkout@v6
- uses: pnpm/action-setup@v4
- name: Setup Node.js environment
uses: actions/setup-node@v6
with:
node-version: 24
cache: pnpm
cache-dependency-path: pnpm-lock.yaml
- name: Install Dependencies
run: pnpm install --frozen-lockfile
- name: Verify packed deps are resolved
run: |
set -euo pipefail
TMP_DIR="$(mktemp -d)"
PACKAGES=(
"@weapp-tailwindcss/runtime"
"@weapp-tailwindcss/merge"
"@weapp-tailwindcss/variants"
"@weapp-tailwindcss/cva"
"@weapp-tailwindcss/typography"
"@weapp-tailwindcss/ui"
"theme-transition"
)
for pkg in "${PACKAGES[@]}"; do
SAFE_PKG="${pkg//@/}"
SAFE_PKG="${SAFE_PKG//\//_}"
PKG_DIR="$TMP_DIR/$SAFE_PKG"
mkdir -p "$PKG_DIR"
pnpm --filter "$pkg" pack --pack-destination "$PKG_DIR"
TARBALL="$(ls "$PKG_DIR"/*.tgz | head -n 1)"
tar -xzf "$TARBALL" -C "$PKG_DIR" package/package.json
if grep -n '"workspace:\*"' "$PKG_DIR/package/package.json"; then
echo "ERROR: workspace:* found in packed package.json for $pkg"
exit 1
fi
done
- name: Build release artifacts
run: pnpm build
- name: Test release artifacts
run: pnpm test:release