mirror of
https://github.com/VibedByKaKi/t3-code-android-nightly.git
synced 2026-10-13 05:47:44 +02:00
49 lines
1.6 KiB
YAML
49 lines
1.6 KiB
YAML
name: Snapshot
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
branches: [main]
|
|
workflow_dispatch:
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
permissions: {}
|
|
|
|
jobs:
|
|
approval-gate:
|
|
if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository
|
|
runs-on: namespace-profile-linux-small
|
|
environment: fork
|
|
steps:
|
|
- run: echo "Fork PR approved by maintainer."
|
|
|
|
snapshot:
|
|
name: Snapshot
|
|
needs: [approval-gate]
|
|
if: >-
|
|
!cancelled()
|
|
&& (needs.approval-gate.result == 'success' || needs.approval-gate.result == 'skipped')
|
|
&& github.repository_owner == 'Effect-Ts'
|
|
runs-on: namespace-profile-linux-small
|
|
timeout-minutes: 10
|
|
steps:
|
|
- uses: actions/checkout@d23441a48e516b6c34aea4fa41551a30e30af803 # v6
|
|
- name: Install dependencies
|
|
uses: ./.github/actions/setup
|
|
- name: Set strip internals config
|
|
run: |
|
|
sed -i 's/"stripInternal": false/"stripInternal": true/' tsconfig.base.json
|
|
- name: Run codemods
|
|
run: pnpm codemod
|
|
- name: Build package
|
|
env:
|
|
# Leave memory for the runner and package builds on the 8 GB runner.
|
|
# The native TypeScript compiler uses Go's soft memory limit.
|
|
GOMEMLIMIT: 4GiB
|
|
run: pnpm build
|
|
- name: Create snapshot
|
|
id: snapshot
|
|
run: pnpm exec pkg-pr-new publish --pnpm --comment=off ./packages/* ./packages/atom/* ./packages/ai/* ./packages/platform/* ./packages/sql/* ./packages/tools/*
|