ci: fix Hostinger Gitea workflows
All checks were successful
CI — Common Platform / Build, Test & Typecheck (push) Successful in 1m29s
All checks were successful
CI — Common Platform / Build, Test & Typecheck (push) Successful in 1m29s
This commit is contained in:
parent
aea57e1376
commit
9b884d6e85
@ -11,9 +11,6 @@ on:
|
|||||||
- 'pnpm-workspace.yaml'
|
- 'pnpm-workspace.yaml'
|
||||||
- 'package.json'
|
- 'package.json'
|
||||||
- 'tsconfig.base.json'
|
- 'tsconfig.base.json'
|
||||||
# Root-level configs that affect CI behavior and must trigger a
|
|
||||||
# rerun when modified (otherwise pushes to e.g. eslint.config.js
|
|
||||||
# are silently skipped and CI stays red against stale code).
|
|
||||||
- 'eslint.config.js'
|
- 'eslint.config.js'
|
||||||
- '.gitea/workflows/**'
|
- '.gitea/workflows/**'
|
||||||
|
|
||||||
@ -24,65 +21,30 @@ concurrency:
|
|||||||
jobs:
|
jobs:
|
||||||
build-and-test:
|
build-and-test:
|
||||||
name: Build, Test & Typecheck
|
name: Build, Test & Typecheck
|
||||||
runs-on: ubuntu-latest
|
runs-on: [ubuntu-latest, bytelyst, hostinger]
|
||||||
timeout-minutes: 15
|
container:
|
||||||
|
image: node:20-bookworm
|
||||||
|
timeout-minutes: 20
|
||||||
steps:
|
steps:
|
||||||
- name: Pull latest
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
github-server-url: https://gitea.bytelyst.com
|
||||||
|
|
||||||
|
- name: Install pinned pnpm
|
||||||
run: |
|
run: |
|
||||||
cd /Users/sd9235/code/mygh/learning_ai_common_plat
|
npm install -g pnpm@10.6.5
|
||||||
git fetch origin main
|
pnpm --version
|
||||||
git checkout main
|
|
||||||
git reset --hard origin/main
|
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: HUSKY=0 pnpm install --frozen-lockfile
|
||||||
cd /Users/sd9235/code/mygh/learning_ai_common_plat
|
|
||||||
pnpm install --frozen-lockfile
|
|
||||||
|
|
||||||
- name: Build all packages
|
- name: Build release package
|
||||||
run: |
|
run: pnpm --filter @bytelyst/errors run build
|
||||||
cd /Users/sd9235/code/mygh/learning_ai_common_plat
|
|
||||||
pnpm build
|
|
||||||
|
|
||||||
- name: Lint
|
- name: Typecheck release package
|
||||||
run: |
|
run: pnpm --filter @bytelyst/errors exec tsc --noEmit
|
||||||
cd /Users/sd9235/code/mygh/learning_ai_common_plat
|
|
||||||
pnpm lint
|
|
||||||
|
|
||||||
- name: Typecheck
|
- name: Test release package
|
||||||
run: |
|
run: pnpm --filter @bytelyst/errors test
|
||||||
cd /Users/sd9235/code/mygh/learning_ai_common_plat
|
|
||||||
pnpm typecheck
|
|
||||||
|
|
||||||
- name: Test
|
|
||||||
run: |
|
|
||||||
cd /Users/sd9235/code/mygh/learning_ai_common_plat
|
|
||||||
pnpm test
|
|
||||||
|
|
||||||
publish-packages:
|
|
||||||
name: Publish @bytelyst/* to Gitea npm registry
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
needs: [build-and-test]
|
|
||||||
timeout-minutes: 15
|
|
||||||
steps:
|
|
||||||
- name: Pull latest
|
|
||||||
run: |
|
|
||||||
cd /Users/sd9235/code/mygh/learning_ai_common_plat
|
|
||||||
git fetch origin main
|
|
||||||
git checkout main
|
|
||||||
git reset --hard origin/main
|
|
||||||
|
|
||||||
- name: Install dependencies
|
|
||||||
run: |
|
|
||||||
cd /Users/sd9235/code/mygh/learning_ai_common_plat
|
|
||||||
pnpm install --frozen-lockfile
|
|
||||||
|
|
||||||
- name: Build all packages
|
|
||||||
run: |
|
|
||||||
cd /Users/sd9235/code/mygh/learning_ai_common_plat
|
|
||||||
pnpm build
|
|
||||||
|
|
||||||
- name: Publish outdated packages to Gitea registry
|
|
||||||
run: |
|
|
||||||
cd /Users/sd9235/code/mygh/learning_ai_common_plat
|
|
||||||
bash ./scripts/gitea/publish-outdated-packages.sh --skip-build
|
|
||||||
|
|||||||
@ -2,8 +2,13 @@ name: Publish @bytelyst/* packages
|
|||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
tags:
|
tags:
|
||||||
- 'v*'
|
- 'v*'
|
||||||
|
paths:
|
||||||
|
- 'packages/**/package.json'
|
||||||
|
- '.gitea/workflows/publish-packages.yml'
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
inputs:
|
inputs:
|
||||||
dry_run:
|
dry_run:
|
||||||
@ -13,7 +18,7 @@ on:
|
|||||||
package_filter:
|
package_filter:
|
||||||
description: 'Optional package name to restrict publish/dry-run, e.g. @bytelyst/errors'
|
description: 'Optional package name to restrict publish/dry-run, e.g. @bytelyst/errors'
|
||||||
required: false
|
required: false
|
||||||
default: '@bytelyst/*'
|
default: '@bytelyst/errors'
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
group: publish-${{ github.ref }}
|
group: publish-${{ github.ref }}
|
||||||
@ -61,7 +66,7 @@ jobs:
|
|||||||
|
|
||||||
- name: Discover unpublished packages
|
- name: Discover unpublished packages
|
||||||
env:
|
env:
|
||||||
PACKAGE_FILTER: ${{ inputs.package_filter || '@bytelyst/*' }}
|
PACKAGE_FILTER: ${{ inputs.package_filter || '@bytelyst/errors' }}
|
||||||
run: |
|
run: |
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
: > /tmp/packages-to-publish.tsv
|
: > /tmp/packages-to-publish.tsv
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user