Skip to content

ci: design-tokens 동기화 자동 PR 워크플로우 등록 #24#25

Merged
Roy-wonji merged 2 commits into
developfrom
ci/design-tokens-sync
May 11, 2026
Merged

ci: design-tokens 동기화 자동 PR 워크플로우 등록 #24#25
Roy-wonji merged 2 commits into
developfrom
ci/design-tokens-sync

Conversation

@Roy-wonji
Copy link
Copy Markdown
Contributor

개요

workflow_dispatch / repository_dispatch 트리거가 모든 브랜치에서 동작하도록 default branch(develop)에 워크플로우 파일을 등록합니다.

변경

  • .github/workflows/sync-design-tokens.yml 신설
    • 트리거: workflow_dispatch, repository_dispatch(design-tokens-updated)
    • 동작: SWYP-Find/design-tokensMode 1.tokens.json 다운로드 → swift Tools/TokenGenerator.swift 실행 → 변경 있으면 develop 대상 PR 자동 생성

머지 후 필요한 secrets

  • Picke-iOS: `DESIGN_TOKENS_TOKEN` (design-tokens 읽기 권한 PAT)
  • design-tokens: `IOS_REPO_DISPATCH_TOKEN` (Picke-iOS Actions 트리거 권한 PAT)

테스트 플랜

  • 머지 후 Actions 탭에서 Sync Design Tokens 수동 실행
  • design-tokens 레포에서 토큰 한 줄 수정 후 push → 자동 PR 생성 확인

Roy-wonji added 2 commits May 11, 2026 16:15
- SWYP-Find/design-tokens 의 Mode 1.tokens.json 을 가져와 TokenGenerator를 돌리고 변경이 있으면 develop 대상 PR 생성
- workflow_dispatch · 매일 10:00 KST 스케줄 · design-tokens 측 repository_dispatch 트리거 지원
- 동작에 secrets.DESIGN_TOKENS_TOKEN (private repo 읽기 권한 PAT) 필요
- 일일 스케줄 제거하고 workflow_dispatch 와 repository_dispatch(design-tokens-updated) 만 유지
- 디자인 토큰 레포의 push 알림이 도착할 때 실 변경분만 PR로 올라가도록 정리
@Roy-wonji Roy-wonji merged commit 26ee934 into develop May 11, 2026
3 checks passed
@Roy-wonji
Copy link
Copy Markdown
Contributor Author

fast-forward로 develop에 직접 push되어 자동 종료

@Roy-wonji Roy-wonji deleted the ci/design-tokens-sync branch May 11, 2026 07:17
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 26ee934221

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

echo "[sync] downloaded $(wc -c < "${LOCAL_JSON_PATH}") bytes"

- name: Run TokenGenerator
run: swift Tools/TokenGenerator.swift
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Point workflow to a real TokenGenerator script

This step runs swift Tools/TokenGenerator.swift, but this commit does not add that file (and the repo tree at this revision has no Tools/TokenGenerator.swift), so every workflow run will fail before change detection or PR creation. Unless the script path is corrected to an existing file in the repository, the automation introduced here cannot succeed.

Useful? React with 👍 / 👎.

Comment on lines +59 to +60
if git diff --quiet -- \
"${LOCAL_JSON_PATH}" \
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Include untracked files in change detection

Using git diff --quiet here only checks tracked modifications and ignores newly created files, so the workflow can report changed=false even when the generator creates new token outputs. In this revision, several target paths are not tracked yet, which means the first sync can silently skip PR creation despite producing files.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant