feat: Add update-tmp-font-asset composite action for TMP FontAsset character registration - #37
feat: Add update-tmp-font-asset composite action for TMP FontAsset character registration#37kochounoyume with Copilot wants to merge 4 commits into
Conversation
…AssetUpdater.cs Co-authored-by: kochounoyume <78918084+kochounoyume@users.noreply.github.com> Agent-Logs-Url: https://github.com/AndanteTribe/Actions/sessions/c9257e13-e6ed-49ff-8b76-3923596ba830
| custom-image: | ||
| description: 'Custom Docker image for the Unity builder (e.g., ghcr.io/owner/ugui-base:latest). Uses the pre-built uGUI base image for faster execution.' | ||
| required: false |
There was a problem hiding this comment.
.github/workflows/build-ugui-base.yml で作成したイメージを使うので、ユーザーからの指定は不要。
There was a problem hiding this comment.
Removed the custom-image input. The ugui-base image is now automatically determined from github.action_repository (commit 031d615).
| cp -r "${{ github.action_path }}/../../src/UGUIBase.Unity" "${{ github.workspace }}/_TmpFontUpdaterProject" | ||
| mkdir -p "${{ github.workspace }}/_TmpFontUpdaterProject/Assets/TmpFontUpdater" |
There was a problem hiding this comment.
イメージを事前にビルドしてPackagesにpublishしているはずなので、こんなやり方とらないでください。.github/workflows/build-ugui-base.yml を参照してください
There was a problem hiding this comment.
Replaced the manual cp -r with actions/checkout@v4 that checks out AndanteTribe/Actions (same repo and ref as the action itself) into _andantetribe-actions, then uses projectPath: _andantetribe-actions/src/UGUIBase.Unity — mirroring how build-ugui-base.yml uses the project from a workspace checkout (commit 031d615).
…base image Co-authored-by: kochounoyume <78918084+kochounoyume@users.noreply.github.com> Agent-Logs-Url: https://github.com/AndanteTribe/Actions/sessions/3d51c10f-9a39-42fc-9434-c29e130b2daf
| - name: Checkout AndanteTribe/Actions | ||
| uses: actions/checkout@v4 | ||
| with: | ||
| repository: ${{ github.action_repository }} | ||
| ref: ${{ github.action_ref }} | ||
| path: _andantetribe-actions |
There was a problem hiding this comment.
@copilot .github/workflows/build-ugui-base.yml や src/UGUIBase.Unity/Dockerfile を把握していないのか?チェックアウトしなくてもイメージ内に含まれていると思うのだが...もしそうでない、私の誤解だというなら指摘してほしいが。.github/workflows/build-ugui-base.yml でpublishされるイメージを使ってほしい
There was a problem hiding this comment.
You're correct — the image DOES have the full project at /root/project via COPY . /root/project in the Dockerfile. The previous approach was wrong: game-ci/unity-builder always mounts the HOST's projectPath into the container and runs Unity against that, so the image's /root/project was never used. That's why the checkout was there.
The fix in commit 2413701 drops both game-ci/unity-builder and the checkout entirely. We now docker run directly against the published ugui-base image, bind-mounting only the font assets and params into the image's existing /root/project structure. License activation, the Unity build method, and license return all happen inside that single container run.
…t and game-ci dependency Co-authored-by: kochounoyume <78918084+kochounoyume@users.noreply.github.com> Agent-Logs-Url: https://github.com/AndanteTribe/Actions/sessions/78cfcfae-a1f9-4bfc-9f03-14bbe935c4d2
Implements a reusable composite action that updates TMP FontAsset registered characters via
TMP_FontAsset.TryAddCharacters, running Unity directly inside the pre-builtugui-baseimage (published bybuild-ugui-base.yml).actions/update-tmp-font-asset/action.yml(new)font-asset-paths(newline-separated, workspace-relative),characters,include-font-features(default:false),unity-licenseresult(true/false),missing-charactersugui-baseimage (built by.github/workflows/build-ugui-base.yml) already contains the full Unity project at/root/projectviaCOPY . /root/projectin its Dockerfile — no checkout of this repository is neededdocker rundirectly againstghcr.io/{owner}/ugui-base:latest; owner is auto-derived fromgithub.action_repository.asset+.meta) into a temp_TmpFontUpdater/Assets/TmpFontUpdater/directory and bind-mounts it into the container at/root/project/Assets/TmpFontUpdaterbase64 | tr -d '\n'for cross-platform compatibility; bind-mounted into the container:ro(avoids passing large XML as an env var)-manualLicenseFile, invokesFontAssetUpdater.InsertCharacters, copies the result file to a shared bind-mounted output directory, returns the licensesrc/UGUIBase.Unity/Assets/Editor/FontAssetUpdater.cs(completed)Completes the existing stub. Reads
tmp-font-update-params.txtfrom the project root, then for each asset:Writes
tmp-font-asset-result.txt(result=true/false,missingCharacters=...) for the action to consume as step outputs.Example usage
Original prompt
📱 Kick off Copilot coding agent tasks wherever you are with GitHub Mobile, available on iOS and Android.