Issue pull-request
課題(バグ・機能など)をissue
として作成、対応するブランチ上で編集作業して、その内容をcommit
,push
して最後にcloseする。こうすることで、どのような修正がどのような目的か明確になる。またリリース時にリリースノートに反映することができる。
プルリクエストでプロジェクトに貢献(日本語字幕できるのでわかりやすい)
VSCodeでプルリクエスト
Issueを作成して、クローズするまで:
Isuue
リポジトリに問題を作成して、作業の計画、議論、追跡を行うことができます。 GitHub CLIを使って実行します(当然WebからもOK)。
gh issue create
Creating issue in hkawa90/astro-starlight-obsidian-template
? Title Update astro for moderate.? Body <Received>? What's next? Add metadata? What would you like to add? Assignees? Assignees hkawa90 (Hideo Kawamura)? What's next? Submithttps://github.com/hkawa90/astro-starlight-obsidian-template/issues/1
gh issue develop 1 --checkout # 1はissue番号
Pull request
pull request は、あるブランチから別のブランチに一連の変更をマージする提案です。 GitHub CLIを使って実行します(当然WebからもOK)。
issueと紐づけるにはpull request
本文にissue番号を含む文字列を記入することで、自動的に実行される。下記例ではclose #2
.
gh pr create -b "close #2"Warning: 3 uncommitted changes
Creating pull request for 2-vulnerability-see-httpsgithubcomadvisoriesghsa-m85w-3h95-hcf9 into main in hkawa90/astro-starlight-obsidian-template
? Title up astro to 4.16.6? What's next? Submithttps://github.com/hkawa90/astro-starlight-obsidian-template/pull/3
一人開発なのでmerge
できれば、終わり
# viewで問題ないことを確認gh pr view 3# view確認後merge requestを出すgh pr merge 3 --merge --delete-branch