以下の内容はhttps://tsubalog.hatenablog.com/entry/2026/01/12/223711より取得しました。


.github/PULL_REQUEST_TEMPLATE.md のメモ

.github/PULL_REQUEST_TEMPLATE.md とは

.github/PULL_REQUEST_TEMPLATE.md は、リポジトリの Pull Request を作成するときのテンプレートファイルです。
.github ディレクトリの他、リポジトリルートや docs ディレクトリに配置することもできます。

  • .github/ISSUE_TEMPLATE/config.yml
    • [New Issue] ボタンを押したときの挙動を設定するファイル
    • blank_issues_enabled : 空の Issue を作成できるかどうか
    • contact_links : 特定の種別の課題に関する外部リンク
  • .github/ISSUE_TEMPLATE のその他の *.yml ファイル
    • 独自の Issue テンプレートファイル

作り方

ゼロから書く必要があります。
テンプレートが1つでよければ .github/PULL_REQUEST_TEMPLATE.md を作ります。
複数のテンプレートを使用する場合は .github/PULL_REQUEST_TEMPLATE/ ディレクトリを作成し、その中に複数の *.md ファイルを配置します。

詳細はドキュメントに記載されています。

docs.github.com

参考:PowerToys

microsoft/PowerToysリポジトリでは、 .github/pull_request_template.md がテンプレートとなっています。
内容はチェックリスト、説明欄、検証手順といった項目が含まれています。

github.com

.github/PULL_REQUEST_TEMPLATE.md の表示箇所

リポジトリに .github/PULL_REQUEST_TEMPLATE.md ファイルがある場合、Pull Request の作成時にテンプレートが選択されます。

ただし複数のテンプレートがリポジトリにある場合、通常手順の Pull Request 作成画面ではテンプレートを選択できないため、URL でテンプレートを指定する必要があります。

  1. pull_request_template1.md というテンプレートの場合
    • https://github.com/<org>/<repo>/compare/<base-branch>...<compare-branch>?quick_pull=1&template=pull_request_template1.md
  2. pull_request_template2.md というテンプレートの場合
    • https://github.com/<org>/<repo>/compare/<base-branch>...<compare-branch>?quick_pull=1&template=pull_request_template2.md
  3. pull_request_template3.md というテンプレートの場合
    • https://github.com/<org>/<repo>/compare/<base-branch>...<compare-branch>?quick_pull=1&template=pull_request_template3.md

まとめ

.github に配置できるファイルの一覧はこちらの記事でまとめています。

tsubalog.hatenablog.com




以上の内容はhttps://tsubalog.hatenablog.com/entry/2026/01/12/223711より取得しました。
このページはhttp://font.textar.tv/のウェブフォントを使用してます

不具合報告/要望等はこちらへお願いします。
モバイルやる夫Viewer Ver0.14