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
7 changes: 4 additions & 3 deletions .github/workflows/upload.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ on:
pull_request: {}

concurrency:
group: cos-upload-${{ github.repository }}-${{ github.event_name == 'pull_request' && 'pr' || 'production' }}
group: cos-upload-${{ github.repository }}-${{ github.event_name == 'pull_request' && format('pr-{0}', github.event.pull_request.number) || 'production' }}
queue: max
cancel-in-progress: false

jobs:
Expand Down Expand Up @@ -61,7 +62,7 @@ jobs:
run: |
set -euo pipefail
if [[ "$GITHUB_EVENT_NAME" == "pull_request" ]]; then
asset_prefix="${GITHUB_REPOSITORY}/pr/${PR_NUMBER}/"
asset_prefix="${GITHUB_REPOSITORY}/pr/${PR_NUMBER}/${GITHUB_RUN_ID}/${GITHUB_RUN_ATTEMPT}/"
else
asset_prefix="${GITHUB_REPOSITORY}/"
fi
Expand All @@ -74,7 +75,7 @@ jobs:

- name: Upload static assets to COS
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name == github.repository
uses: worktools/cos-upload-action@17e6d213fe9f6772a6090a13c8ba044cd6cbcb09 # v1.1.1
uses: worktools/cos-upload-action@06d6027dcca6413c5936e04a9b6e9f0d5ef71ba0 # v1.2.0
with:
source-dir: dist
bucket: ${{ secrets.COS_BUCKET }}
Expand Down
16 changes: 14 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,22 @@ Calcit 0.27.0 uses `calcit.cirru` and `deps.cirru` as the canonical project file
`yarn build` generates JavaScript explicitly and uses `VITE_BASE_URL` for frontend assets (relative URLs when unset). CI builds with the COS prefix:

```bash
VITE_BASE_URL=https://cos-sh.tiye.me/mvc-works/text-diff/pr/ yarn build
VITE_BASE_URL=https://cos-sh.tiye.me/mvc-works/text-diff/ yarn build
```

Public upload verification uses `worktools/cos-upload-action`'s built-in verify settings, without an extra CDN checker. Existing server deployment paths and shared fonts/icons are unchanged.
Public upload verification uses `worktools/cos-upload-action` v1.2.0's built-in
verify settings through `public-base-url`, without an extra CDN checker.
The action is pinned to the reviewed commit of that formal release. Existing
server deployment paths and shared fonts/icons are unchanged.

PR 预览路径为 `mvc-works/text-diff/pr/<number>/<run-id>/<attempt>/`,每次
运行及重试隔离,生产路径不变。同一 PR 使用独立上传队列,生产另用一个队列;
保留等待任务,不取消活跃上传。

本轮仅更新 COS/CDN,不改变当前 Calcit 0.27.0、模块版本、源码、锁文件
或原业务测试与类型门禁。主线保留已有 `caps --ci` 模式及其传递版本冲突,
不冒称 strict Caps 已通过。独立 0.28.0 候选仍被共享 Respo/Markdown
合同阻塞,COS 配置通过不代表完整 Calcit 升级完成。

Workflow https://github.com/mvc-works/calcit-workflow

Expand Down
Loading