Pull Request作成・更新時に使用。タイトルと説明文を自動生成・更新する。
/plugin marketplace add syou6162/claude-code-commands/plugin install syou6162-plugin@syou6162-marketplaceThis skill is limited to using the following tools:
Pull Requestのタイトルと説明文を以下の手順で更新してください。
デフォルトブランチの取得
デフォルトブランチを取得:
git symbolic-ref refs/remotes/origin/HEAD --short | cut -d/ -f2
修正内容の確認
デフォルトブランチからの差分を確認:
# <default-branch> には手順1で取得したブランチ名を使用
git diff <default-branch>...HEAD
コミットメッセージの確認
デフォルトブランチからのコミット履歴を確認(本文も含む):
# <default-branch> には手順1で取得したブランチ名を使用
git log <default-branch>..HEAD
説明文ファイルの準備
.github/PULL_REQUEST_TEMPLATE.mdが存在する場合はコピー:
cp .github/PULL_REQUEST_TEMPLATE.md .claude_work/pr_body_draft.md
存在しない場合は新規ファイル作成:
touch .claude_work/pr_body_draft.md
Pull Requestの説明文を作成
.claude_work/pr_body_draft.md)を編集WriteツールまたはEditツールを使用することcat <<EOF > file、echo "..." > fileなど)でファイルを書き込んではいけませんPull Requestの作成または更新
PRの存在確認と作成/更新:
# PRが存在するか確認
if gh pr view >/dev/null 2>&1; then
# PRが存在する場合:更新
gh pr edit --title "修正内容を考慮したタイトル" --body-file .claude_work/pr_body_draft.md
else
# PRが存在しない場合:ドラフトPRを作成
gh pr create --draft --title "修正内容を考慮したタイトル" --body-file .claude_work/pr_body_draft.md
fi
更新後の確認と文字化けチェック
# PRの内容を確認
gh pr view
.claude_work/pr_body_draft.md を確認し、UTF-8エンコーディングで保存されているか確認gh pr edit --body-file .claude_work/pr_body_draft.md で更新gh pr view で確認.github/PULL_REQUEST_TEMPLATE.mdが存在する場合:
.github/PULL_REQUEST_TEMPLATE.mdが存在しない場合:
--draftオプションでドラフトPRを作成gh pr editで内容を更新--body-fileオプションを使用して安全に作成/更新.claude_work/pr_body_draft.md)は削除せず残しておくWriteツールまたはEditツールを使用することcat <<EOF > file、cat << 'EOF' > file、echo "..." > fileなど)でファイルを書き込まないことThis skill should be used when the user asks to "create a hookify rule", "write a hook rule", "configure hookify", "add a hookify rule", or needs guidance on hookify rule syntax and patterns.
Create distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.