AgentStack
SKILL verified MIT Self-run

Autoland

skill-circui-try-circuit-autoland · by CIrcui-try

필요 시 takeoff 후 CI 통과 PR 자동 머지·landing 정리

No reviews yet
0 installs
15 views
0.0% view→install

Install

$ agentstack add skill-circui-try-circuit-autoland

✓ scanned · ✓ verified — works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

Are you the author of Autoland? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

autoland

Use this skill when the user asks to run the autoland workflow.

Command Template

takeoff 이후 사후 자동화 단계. PR 이 아직 없고 이슈 키를 확정할 수 있으면 먼저 takeoff 를 실행해 PR 을 만든다. 이후 PR 의 CI checks 를 기다렸다가 모두 통과하면 merge commit 방식으로 머지하고, 이어서 landing 과 동일하게 로컬 워크트리를 제거하고 develop 을 최신화한다.

$ARGUMENTS 형식: [ISSUE-ID | branch | PR URL] [--interval ] [--timeout ]. 타깃을 생략하면 커맨드를 호출한 위치의 현재 브랜치를 대상으로 한다. 예: /autoland, /autoland CIR-15, /autoland feature/cir-15-fix-..., /autoland https://github.com/OWNER/REPO/pull/123.

인자 파싱

  1. 첫 토큰이 플래그가 아니면 ` 으로 둔다. 없으면 메인 레포로 이동하기 전에 CURRENTBRANCH = $(git branch --show-current) 로 호출 위치의 브랜치를 저장해 기본값으로 사용한다. CURRENTBRANCH` 도 없으면 사용자에게 직접 입력받는다.
  2. --interval 를 파싱한다. 기본값은 30, 1 미만이거나 숫자가 아니면 중단.
  3. --timeout 를 파싱한다. 기본값은 60, 1 미만이거나 숫자가 아니면 중단.

자기 단계 실행 절차

  1. 메인 레포로 이동: 인자 파싱 중 캡처한 CURRENT_BRANCH 를 보존한 채 MAIN_REPO_ROOT = $(git rev-parse --path-format=absolute --git-common-dir | xargs dirname)cd $MAIN_REPO_ROOT.
  2. GitHub 인증 확인: gh-auth-check 스킬로 GitHub CLI 로그인 상태와 active account 를 확인한다.
  3. 대상 결정:
  • `CIR-/PROJ- 같은 이슈 키 패턴이면 ISSUEKEY 로 보존하고, Linear MCP getissuegitBranchName` 을 조회해 branch 로 사용한다.
  • `https://github.com/.../pull/...` 형태면 PR URL 로 사용한다.
  • 그 외에는 branch 로 사용한다. branch 안에 CIR-39 또는 cir-39 같은 이슈 키가 포함되어 있으면 대문자 이슈 키로 정규화해 ISSUE_KEY 로 보존한다.
  1. PR 상태 확인: gh pr view --json number,url,state,isDraft,baseRefName,headRefName,headRefOid,mergeable 실행.
  • PR 을 찾지 못했고 ISSUE_KEY 가 있으면 /takeoff 절차를 먼저 실행한다. takeoff 가 push, rebase, PR 생성, 상태 파일 정리를 처리한다. takeoff 가 사용자 승인 필요 상황(force push, 충돌, 미커밋 변경, 워크트리 없음 등)으로 멈추면 autoland 도 중단한다.
  • takeoff 성공 후 같은 branch 로 gh pr view ... 를 다시 실행해 PR URL, PR number, head branch, head SHA 를 고정한다. 그래도 PR 을 찾지 못하면 중단.
  • PR 을 찾지 못했고 ISSUE_KEY 도 없으면 takeoff 대상을 확정할 수 없으므로 중단한다.
  • stateMERGED 면 머지는 스킵하고 landing 정리만 진행.
  • stateOPEN 이 아니면 중단.
  • isDraft == true 면 중단.
  • baseRefName != "develop" 이면 중단.
  • 이후 단계에서는 PR URL, PR number, head branch, head SHA 를 고정해 사용한다.
  1. CI checks 초기 확인: gh pr checks --json bucket,state,name,workflow,link 실행.
  • 반환된 check 가 0개면 자동 머지하지 않고 중단.
  • bucketfail 또는 cancel 인 check 가 있으면 중단.
  1. CI 대기:
  • gh pr checks --watch --fail-fast --interval 로 checks 종료를 기다린다.
  • 대기 시간이 `` 분을 넘으면 프로세스를 중단하고 자동 머지하지 않는다.
  • watch 가 실패, 취소, timeout 으로 끝나면 원인 check 이름과 링크를 요약하고 중단.
  1. 최종 CI 재확인: gh pr checks --json bucket,state,name,workflow,link 를 다시 실행한다.
  • check 가 0개면 중단.
  • 모든 bucketpass 가 아니면 중단. skipping, pending, fail, cancel 은 자동 머지 대상이 아니다.
  1. 머지 직전 PR 재확인: gh pr view --json state,isDraft,baseRefName,headRefOid,mergeable 실행.
  • PR 이 더 이상 OPEN 이 아니거나 draft 가 되었거나 base 가 develop 이 아니면 중단.
  • headRefOid 가 4단계에서 확인한 SHA 와 다르면 checks 를 다시 기다려야 하므로 중단.
  1. PR 머지: gh pr merge --merge --delete-branch --match-head-commit 실행.
  • --admin, --auto, --squash, --rebase 는 사용하지 않는다.
  • branch protection, required review, merge conflict, 권한 오류는 우회하지 않고 중단.
  1. 로컬 정리: 기존 /landing 절차와 동일하게 진행한다.
  • 이슈 키로 호출된 경우 원래 `/landing` 입력으로 사용한다.
  • PR URL 로 호출된 경우 4단계의 headRefName 을 branch 입력으로 사용한다.
  • 워크트리가 없으면 landing 처럼 스킵 메시지만 출력하고 계속한다.
  1. 티켓 상태 동기화: PR 머지와 landing 정리가 끝났고 이슈 키를 확인할 수 있으면 Linear 상태를 Done 으로 직접 변경한다.
  2. 직접 확인 포인트 정리: PR 본문의 Manual verification 섹션을 우선 사용하고, 없으면 PR diff/커밋/Linear 이슈 내용을 보고 사용자가 직접 확인할 수 있는 가시적인 피처를 1~5개로 정리한다.
  • 화면, 버튼, 리스트, 상태 표시, 알림, 에러 메시지, 사용자 플로우처럼 눈으로 확인 가능한 단위로 쓴다.
  • 코드 정리, 테스트, 인프라 변경처럼 직접 확인할 UI/동작이 없으면 "직접 확인할 가시 피처 없음" 이라고 명시한다.
  • 애매하면 근거를 짧게 붙여 추정이라고 표시한다.
  1. 요약 출력: PR URL, checks 통과 여부, merge commit 방식으로 머지했는지, landing 정리 결과, 직접 확인 포인트를 함께 안내한다.

주의사항

  • failed, cancelled, timed-out checks 는 자동 머지하지 않는다.
  • checks 가 하나도 없으면 자동 머지하지 않는다.
  • draft PR, closed PR, base 가 develop 이 아닌 PR 은 중단한다.
  • branch protection, review requirement, merge conflict 는 우회하지 않는다.
  • --admin, --auto, force push, develop 직접 push 는 사용하지 않는다.
  • Linear 티켓 상태는 자동화에 위임하지 않고 직접 TodoIn ProgressDone 으로만 처리한다.
  • 웹훅 서버 방식은 v1 범위가 아니다. 이 커맨드는 로컬 GitHub CLI 폴링 기반으로 동작한다.

Codex Invocation

Use this as a Codex project skill. Invoke autoland with the optional issue id, branch, or PR URL and flags as described above; when no target is provided, use the current branch captured before moving to the main repo.

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet — be the first.

Versions

  • v0.1.0 Imported from the upstream source.