{"id":3117,"date":"2015-09-03T11:28:45","date_gmt":"2015-09-03T02:28:45","guid":{"rendered":"http:\/\/aatljapan.wpengine.com\/?p=3117"},"modified":"2015-09-03T11:28:45","modified_gmt":"2015-09-03T02:28:45","slug":"the-power-of-git-subtree","status":"publish","type":"post","link":"https:\/\/www.atlassian.com\/ja\/blog\/the-power-of-git-subtree","title":{"rendered":"Git subtree \u306e\u30d1\u30ef\u30fc"},"content":{"rendered":"<p><a href=\"http:\/\/git.kernel.org\/cgit\/git\/git.git\/plain\/contrib\/subtree\/git-subtree.txt\">Git subtree<\/a> \u3092\u4f7f\u3046\u3068\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u4ed6\u306e\u30ea\u30dd\u30b8\u30c8\u30ea\u306e\u30b5\u30d6\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3068\u3057\u3066\u8ffd\u52a0\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002Git \u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u304c<a href=\"http:\/\/blogs.atlassian.com\/2014\/04\/git-project-dependencies\/\">\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u4f9d\u5b58\u95a2\u4fc2\u3092\u7ba1\u7406<\/a>\u3059\u308b\u65b9\u6cd5\u306f\u3044\u304f\u3064\u304b\u3042\u308a\u307e\u3059\u304c\u3001\u3053\u308c\u306f\u305d\u306e\u4e00\u3064\u3067\u3059\u3002\u8a18\u61b6\u529b\u306e\u826f\u3044\u4eba\u306f\u3001\u79c1\u304c\u4ee5\u524d\u306b <a href=\"http:\/\/aatljapan.wpengine.com\/2014\/03\/alternatives-to-git-submodule-git-subtree\/\">Git submodule \u306e\u4ee3\u66ff<\/a>\u306e\u8a18\u4e8b\u3067\u3053\u306e\u30b3\u30de\u30f3\u30c9\u306e\u4f7f\u7528\u6cd5\u3068\u5229\u70b9\u306b\u3064\u3044\u3066\u66f8\u3044\u305f\u3053\u3068\u3092\u899a\u3048\u3066\u3044\u308b\u3067\u3057\u3087\u3046\u3002<\/p>\n<h2 id=\"the-basics-of-git-subtree\">Git subtree \u306e\u57fa\u672c<\/h2>\n<p>\u305d\u308c\u3067\u306f <tt>git subtree<\/tt> \u304c\u3042\u306a\u305f\u306b\u3068\u3063\u3066\u6709\u76ca\u304b\u3069\u3046\u304b\u3092\u5224\u65ad\u3059\u308b\u305f\u3081\u3001\u57fa\u672c\u3092\u632f\u308a\u8fd4\u3063\u3066\u307f\u307e\u3057\u3087\u3046\u3002\u60f3\u50cf\u3057\u3066\u4e0b\u3055\u3044\u3002\u3042\u306a\u305f\u306f\u81ea\u5206\u306e\u6301\u3064\u30ea\u30dd\u30b8\u30c8\u30ea\u306b\u5916\u90e8\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u3092\u3044\u304f\u3064\u304b\u8ffd\u52a0\u3057\u305f\u3044\u304c\u3001\u3042\u306a\u305f\u3084\u540c\u50da\u306e\u65e5\u3005\u306e\u5229\u7528\u3059\u308b\u3082\u306e\u306b\u305f\u304f\u3055\u3093\u306e\u3082\u306e\u3092\u8ffd\u52a0\u3057\u305f\u304f\u306f\u3042\u308a\u307e\u305b\u3093\u3002\u3053\u306e\u3088\u3046\u306a\u5834\u5408\u306b <tt>subtree<\/tt> \u30b3\u30de\u30f3\u30c9\u306f\u5f79\u7acb\u3061\u307e\u3059\u3002<\/p>\n<p> \u4f8b\u3048\u3070 vim \u8a2d\u5b9a\u3092\u4fdd\u5b58\u3057\u3066\u3044\u308b\u30ea\u30dd\u30b8\u30c8\u30ea\u306b vim \u62e1\u5f35\u3092\u8ffd\u52a0\u3057\u305f\u3044\u5834\u5408\u306f\u3053\u306e\u3088\u3046\u306b\u3057\u307e\u3059: <\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/aatljapan.wpengine.com\/files\/Screen-Shot-2015-09-02-at-1.54.15-PM.png\" alt=\"Screen Shot 2015-09-02 at 1.54.15 PM\" width=\"644\" height=\"55\" class=\"aligncenter size-full wp-image-3121\" srcset=\"https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-1.54.15-PM.png 644w, https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-1.54.15-PM-300x26.png 300w\" sizes=\"auto, (max-width: 644px) 100vw, 644px\" \/><\/p>\n<p>\u3053\u306e\u30b3\u30de\u30f3\u30c9\u306f\u3001<tt>vim-fireplace<\/tt> \u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u5168\u5c65\u6b74\u3092\u30d5\u30a9\u30eb\u30c0\u30fc <tt>.vim\/bundle\/fireplace<\/tt> \u306b\u307e\u3068\u3081\u308b\u3068\u540c\u6642\u306b\u3001\u4eca\u5f8c\u306e\u305f\u3081\u306b <tt>master<\/tt> \u306e SHA-1 \u3092\u8a18\u9332\u3057\u307e\u3059\u3002squash \u3067\u307e\u3068\u3081\u3089\u308c\u305f <tt>git subtree add<\/tt> \u306e\u7d50\u679c\u306f 2 \u3064\u306e\u30b3\u30df\u30c3\u30c8\u306b\u306a\u308a\u307e\u3059:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/aatljapan.wpengine.com\/files\/Screen-Shot-2015-09-02-at-1.56.00-PM.png\" alt=\"Screen Shot 2015-09-02 at 1.56.00 PM\" width=\"643\" height=\"258\" class=\"aligncenter size-full wp-image-3122\" srcset=\"https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-1.56.00-PM.png 643w, https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-1.56.00-PM-300x120.png 300w\" sizes=\"auto, (max-width: 643px) 100vw, 643px\" \/><\/p>\n<p>\u3042\u3068\u3067\u3053\u306e\u30b5\u30d6\u30d5\u30a9\u30eb\u30c0\u3092\u5b50\u30ea\u30dd\u30b8\u30c8\u30ea\u306e\u6700\u65b0\u7248\u306b\u66f4\u65b0\u3057\u305f\u3044\u5834\u5408\u306f\u3001<tt>subtree pull<\/tt> \u306b\u540c\u3058\u30d1\u30e9\u30e1\u30fc\u30bf\u3092\u4ed8\u3051\u3066\u5b9f\u884c\u3057\u307e\u3059:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/aatljapan.wpengine.com\/files\/Screen-Shot-2015-09-02-at-2.09.50-PM.png\" alt=\"Screen Shot 2015-09-02 at 2.09.50 PM\" width=\"643\" height=\"49\" class=\"aligncenter size-full wp-image-3123\" srcset=\"https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.09.50-PM.png 643w, https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.09.50-PM-300x23.png 300w\" sizes=\"auto, (max-width: 643px) 100vw, 643px\" \/><\/p>\n<p>\u57fa\u672c\u7684\u306a\u4f7f\u7528\u6cd5\u306f\u4ee5\u4e0a\u3067\u3059\u3002\u3055\u3089\u306b\u614e\u91cd\u304b\u3064\u8a08\u753b\u7684\u306b\u884c\u3044\u305f\u3044\u5834\u5408\u306f\u3001\u5b50\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u30bf\u30b0\u3092\u4ed8\u3051\u305f\u30ea\u30d3\u30b8\u30e7\u30f3 (<tt>v1.0<\/tt> \u306a\u3069) \u306e\u307f <tt>add<\/tt> \u3084 <tt>pull<\/tt> \u3092\u884c\u3046\u3068\u826f\u3044\u3067\u3057\u3087\u3046\u3002\u3053\u3046\u3059\u308b\u3053\u3068\u3067\u3001\u307e\u3060\u5b89\u5b9a\u7248\u3067\u306f\u306a\u3044\u304b\u3082\u3057\u308c\u306a\u3044 <tt>master<\/tt> \u304b\u3089\u30b3\u30fc\u30c9\u3092\u30a4\u30f3\u30dd\u30fc\u30c8\u3059\u308b\u3053\u3068\u304c\u9632\u3052\u307e\u3059\u3002<\/p>\n<p><strong>\u6ce8\u610f:<\/strong> <tt>git-subtree<\/tt> \u306f sub-project \u306e\u30b3\u30df\u30c3\u30c8 ID \u3092\u4fdd\u5b58\u3057\u307e\u3059\u304c meta-data \u306e <tt>refs<\/tt> \u306f\u4fdd\u5b58\u3057\u307e\u305b\u3093\u3002\u3057\u304b\u3057\u30b3\u30df\u30c3\u30c8 ID (<tt>sha-1<\/tt>) \u304c\u4e0e\u3048\u3089\u308c\u3066\u3044\u308b\u305f\u3081\u3053\u308c\u306f\u554f\u984c\u3067\u306f\u3042\u308a\u307e\u305b\u3093\u3002<tt>ls-remote<\/tt> \u306e\u3088\u3046\u306a\u30b3\u30de\u30f3\u30c9\u306b\u3088\u3063\u3066\u30b3\u30df\u30c3\u30c8\u306b\u95a2\u9023\u4ed8\u3051\u3089\u308c\u3066\u3044\u308b\u30b7\u30f3\u30dc\u30ea\u30c3\u30af\u540d\u3092\u78ba\u8a8d\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/aatljapan.wpengine.com\/files\/Screen-Shot-2015-09-02-at-2.11.03-PM.png\" alt=\"Screen Shot 2015-09-02 at 2.11.03 PM\" width=\"642\" height=\"34\" class=\"aligncenter size-full wp-image-3124\" srcset=\"https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.11.03-PM.png 642w, https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.11.03-PM-300x16.png 300w\" sizes=\"auto, (max-width: 642px) 100vw, 642px\" \/><\/p>\n<h2 id=\"git-subtree-aliases\">Git subtree \u30a8\u30a4\u30ea\u30a2\u30b9<\/h2>\n<p>subtree \u30b3\u30de\u30f3\u30c9\u3092\u983b\u7e41\u306b\u4f7f\u7528\u3059\u308b\u5834\u5408\u3001<tt>$HOME\/.gitconfig<\/tt> \u306b\u7c21\u5358\u306a\u30a8\u30a4\u30ea\u30a2\u30b9\u3092\u3044\u304f\u3064\u304b\u7528\u610f\u3059\u308b\u3053\u3068\u3067\u3001\u30b3\u30de\u30f3\u30c9\u3092\u77ed\u7e2e\u3057\u7c21\u7d20\u5316\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/aatljapan.wpengine.com\/files\/Screen-Shot-2015-09-02-at-2.11.39-PM.png\" alt=\"Screen Shot 2015-09-02 at 2.11.39 PM\" width=\"643\" height=\"95\" class=\"aligncenter size-full wp-image-3125\" srcset=\"https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.11.39-PM.png 643w, https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.11.39-PM-300x44.png 300w\" sizes=\"auto, (max-width: 643px) 100vw, 643px\" \/><\/p>\n<p>\u79c1\u306f <tt>scp<\/tt> \u30b3\u30de\u30f3\u30c9 (<tt>scp &lt;remote src&gt; &lt;dest&gt;<\/tt>) \u306e\u3088\u3046\u306b\u3057\u3066\u30b5\u30d6\u30c4\u30ea\u30fc\u3092\u8ffd\u52a0\u3057\u305f\u3044\u306e\u3067\u3001\u79c1\u304c\u4f7f\u7528\u3057\u3066\u3044\u308b\u30a8\u30a4\u30ea\u30a2\u30b9\u306f\u30d1\u30e9\u30e1\u30fc\u30bf\u30fc\u306e\u9806\u756a\u3092\u53cd\u5bfe\u306b\u3057\u3066\u3044\u307e\u3059\u3002\u3053\u308c\u306f\u4ee5\u4e0b\u306e\u3088\u3046\u306b\u4f7f\u7528\u3057\u307e\u3059:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/aatljapan.wpengine.com\/files\/Screen-Shot-2015-09-02-at-2.12.13-PM.png\" alt=\"Screen Shot 2015-09-02 at 2.12.13 PM\" width=\"643\" height=\"61\" class=\"aligncenter size-full wp-image-3126\" srcset=\"https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.12.13-PM.png 643w, https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.12.13-PM-300x28.png 300w\" sizes=\"auto, (max-width: 643px) 100vw, 643px\" \/><\/p>\n<h2 id=\"under-the-hood-of-git-subtree\">git subtree \u306e\u5185\u90e8\u3067\u8d77\u3053\u3063\u3066\u3044\u308b\u3053\u3068<\/h2>\n<p> \u79c1\u306f\u6700\u8fd1 <a href=\"http:\/\/git.kernel.org\/cgit\/git\/git.git\/plain\/contrib\/subtree\/git-subtree.sh\">git-subtree<\/a> \u306e\u5b9f\u88c5\u3092\u898b\u305f\u306e\u3067\u3059\u304c\u3001\u305d\u308c\u306f\u3068\u3066\u3082\u8ce2\u304f\u5b9f\u88c5\u3055\u308c\u3066\u3044\u307e\u3057\u305f\u3002\u307e\u305a\u611f\u5fc3\u3057\u305f\u306e\u306f\u3001\u3088\u304f\u77e5\u3063\u3066\u3044\u305f\u3053\u3068\u3067\u3059\u304c\u3001Git subtree \u306f\u30b7\u30a7\u30eb\u30b9\u30af\u30ea\u30d7\u30c8\u3068\u3057\u3066\u5b9f\u88c5\u3055\u308c\u3066\u3044\u3066\u3001\u3057\u304b\u3082\u305d\u308c\u304c<a href=\"http:\/\/git.kernel.org\/cgit\/git\/git.git\/tree\/contrib\/subtree\/git-subtree.sh\">\u3068\u3066\u3082\u8aad\u307f\u3084\u3059\u3044<\/a>\u3082\u306e\u3060\u3063\u305f\u306e\u3067\u3059\u3002<\/p>\n<p>\u305d\u306e\u30b3\u30de\u30f3\u30c9\u306e\u6838\u3068\u306a\u308b\u30c6\u30af\u30cb\u30c3\u30af\u306f\u3053\u3046\u3067\u3059\u3002<tt>git-subtree<\/tt> \u306f\u3001\u30b3\u30df\u30c3\u30c8\u306b\u76f4\u63a5\u30a4\u30f3\u30dd\u30fc\u30c8\u3059\u308b\u30b3\u30fc\u30c9\u306e\u5916\u90e8 meta-data \u3092\u4fdd\u5b58\u3057\u307e\u3059\u3002\u4f8b\u3048\u3070 <tt>squashed pull<\/tt> (\u307e\u3068\u3081\u3089\u308c\u305f\u30d7\u30eb) \u306f\u3001\u30de\u30fc\u30b8\u524d\u306b\u3053\u308c\u3089 2 \u3064\u306e\u5024\u3092\u30b3\u30df\u30c3\u30c8\u30e1\u30c3\u30bb\u30fc\u30b8\u306b\u4fdd\u5b58\u3057\u307e\u3059:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/aatljapan.wpengine.com\/files\/Screen-Shot-2015-09-02-at-2.12.49-PM.png\" alt=\"Screen Shot 2015-09-02 at 2.12.49 PM\" width=\"643\" height=\"48\" class=\"aligncenter size-full wp-image-3127\" srcset=\"https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.12.49-PM.png 643w, https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.12.49-PM-300x22.png 300w\" sizes=\"auto, (max-width: 643px) 100vw, 643px\" \/><\/p>\n<p> <tt>git-subtree-split<\/tt> \u30d5\u30a3\u30fc\u30eb\u30c9\u306b\u306f\u3001<tt>git-subtree-dir<\/tt> \u30d5\u30a9\u30eb\u30c0\u30fc\u306b\u8ffd\u52a0\u3055\u308c\u3066\u3044\u305f\u30b5\u30d6\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306e\u30b3\u30df\u30c3\u30c8 ID (<tt>sha-1<\/tt>) \u3092\u8a18\u9332\u3057\u3066\u3044\u307e\u3059\u3002\u30b7\u30f3\u30d7\u30eb\u3067\u3059\u306d! \u3053\u306e\u60c5\u5831\u3092\u4f7f\u3046\u3053\u3068\u3067\u3001\u6b21\u306b\u5b9f\u884c\u3055\u308c\u308b <tt>git subtree pull<\/tt> \u304c\u4ee5\u524d\u306b\u7d71\u5408\u3057\u305f\u6642\u70b9\u306e\u3082\u306e\u3092\u5f15\u304d\u51fa\u3057\u3001\u6b21\u56de\u306e squash \u3084 merge \u306e\u30d9\u30fc\u30b9\u3068\u3057\u3066\u4f7f\u7528\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002 <\/p>\n<h2 id=\"rebase-after-a-git-subtree\">git subtree \u4ee5\u964d\u306e\u30ea\u30d9\u30fc\u30b9<\/h2>\n<p>\u3042\u306a\u305f\u306f sub-tree \u306e\u542b\u307e\u308c\u308b\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u3069\u3046\u3084\u3063\u3066\u30ea\u30d9\u30fc\u30b9\u3057\u3066\u3044\u307e\u3059\u304b? <a href=\"http:\/\/stackoverflow.com\/questions\/12858199\/how-to-rebase-after-git-subtree-add\">\u3053\u306e Stack Overflow \u306b\u95a2\u3059\u308b\u8b70\u8ad6<\/a>\u304b\u3089\u5206\u304b\u308b\u3053\u3068\u306f\u3001\u9280\u306e\u5f3e\u4e38\u306f\u5b58\u5728\u3057\u306a\u3044\u3068\u3044\u3046\u3053\u3068\u3067\u3059\u3002<\/p>\n<p>\u6709\u52b9\u306a\u624b\u9806\u306f\u3001\u624b\u52d5\u3067\u30ea\u30d9\u30fc\u30b9\u3092\u884c\u3046\u305f\u3081\u306b\u5358\u7d14\u306b <tt>rebase --interactive<\/tt> \u3092\u5b9f\u884c\u3057\u3001<tt>git subtree add<\/tt> \u306e\u30b3\u30df\u30c3\u30c8\u3092\u524a\u9664\u3057\u3066 <tt>rebase --continue<\/tt> \u3092\u5b9f\u884c\u3057\u3001\u30ea\u30d9\u30fc\u30b9\u304c\u5b8c\u4e86\u3057\u305f\u3089 <tt>git subtree add<\/tt> \u30b3\u30de\u30f3\u30c9\u3092\u518d\u5b9f\u884c\u3059\u308b\u3053\u3068\u3060\u3068\u601d\u3044\u307e\u3059\u3002 <\/p>\n<h2 id=\"hacking-on-git-subtree\">git-subtree \u306e\u30cf\u30c3\u30af<\/h2>\n<p>\u5c0f\u3055\u306a\u3053\u3068\u3067\u3059\u304c\u3001\u79c1\u304c\u6c17\u3065\u3044\u305f\u30c7\u30d5\u30a9\u30eb\u30c8\u306e\u30b3\u30de\u30f3\u30c9\u306b\u6b20\u3051\u3066\u3044\u308b\u3082\u306e\u306f\u3001\u8ffd\u52a0\u3059\u308b\u30aa\u30ea\u30b8\u30ca\u30eb\u30ea\u30dd\u30b8\u30c8\u30ea\u306e URL \u304c\u4fdd\u5b58\u3055\u308c\u306a\u3044\u3068\u3044\u3046\u3053\u3068\u3067\u3059\u3002\u6700\u8fd1 vim \u62e1\u5f35\u3092\u5168\u3066\u66f4\u65b0\u3057\u3088\u3046\u3068\u3057\u3066\u3044\u305f\u6642\u306b\u3053\u306e\u3053\u3068\u3092\u601d\u3044\u51fa\u3057\u307e\u3057\u305f\u3002\u79c1\u306f\u3001<tt>git subtree add<\/tt> \u3092\u4f7f\u7528\u3057\u3066\u3053\u308c\u307e\u3067\u306b\u8ffd\u52a0\u3057\u3066\u3044\u305f\u30bd\u30fc\u30b9\u30ea\u30dd\u30b8\u30c8\u30ea\u306e URL \u3092\u5168\u3066\u5fd8\u308c\u3066\u3057\u307e\u3063\u3066\u3044\u307e\u3057\u305f\u3002<\/p>\n<p>\u79c1\u306f\u3001<a href=\"https:\/\/developer.atlassian.com\/blog\/2015\/04\/git-merge-2015-wrap\/\">Git Merge 2015<\/a> \u306b\u53c2\u52a0\u3057\u3066\u4ee5\u6765\u3001\u3053\u306e\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u306b\u8ca2\u732e\u3059\u308b\u65b9\u6cd5\u3092\u71b1\u5fc3\u306b\u63a2\u3057\u3066\u3044\u305f\u305f\u3081\u3001\u81ea\u5206\u81ea\u8eab\u306b\u300c\u6587\u53e5\u3092\u8a00\u3046\u306e\u3067\u306f\u306a\u304f<strong>\u81ea\u5206\u306a\u3089<\/strong>\u6539\u5584\u3067\u304d\u308b\u306f\u305a\u3060!\u300d\u3068\u8a00\u3044\u805e\u304b\u305b\u307e\u3057\u305f\u3002<\/p>\n<p>\u305d\u3053\u3067\u79c1\u306f <tt>git-subtree.sh<\/tt> \u30b9\u30af\u30ea\u30d7\u30c8\u306b\u8ffd\u52a0\u6a5f\u80fd\u3092\u5b9f\u88c5\u3057\u307e\u3057\u305f\u3002<\/p>\n<p>\u79c1\u306f <tt>git subtree add<\/tt> \u304c squash \u3067\u307e\u3068\u3081\u3089\u308c\u305f\u30b3\u30df\u30c3\u30c8\u306b\u60c5\u5831\u3092\u8ffd\u52a0\u3067\u304d\u308b\u3088\u3046\u306b <tt>git-subtree-repo<\/tt> \u3068\u3044\u3046\u62e1\u5f35\u30d5\u30a3\u30fc\u30eb\u30c9\u3092\u8ffd\u52a0\u3057\u307e\u3057\u305f\u3002\u6b21\u306e\u901a\u308a\u3067\u3059:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/aatljapan.wpengine.com\/files\/Screen-Shot-2015-09-02-at-2.14.10-PM.png\" alt=\"Screen Shot 2015-09-02 at 2.14.10 PM\" width=\"643\" height=\"49\" class=\"aligncenter size-full wp-image-3128\" srcset=\"https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.14.10-PM.png 643w, https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.14.10-PM-300x23.png 300w\" sizes=\"auto, (max-width: 643px) 100vw, 643px\" \/><\/p>\n<p>\u62e1\u5f35\u30d5\u30a3\u30fc\u30eb\u30c9\u4ed8\u304d\u306e\u30b3\u30df\u30c3\u30c8\u7d50\u679c\u306f\u3053\u306e\u3088\u3046\u306b\u306a\u308a\u307e\u3059:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/aatljapan.wpengine.com\/files\/Screen-Shot-2015-09-02-at-2.15.54-PM.png\" alt=\"Screen Shot 2015-09-02 at 2.15.54 PM\" width=\"644\" height=\"155\" class=\"aligncenter size-full wp-image-3129\" srcset=\"https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.15.54-PM.png 644w, https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.15.54-PM-300x72.png 300w\" sizes=\"auto, (max-width: 644px) 100vw, 644px\" \/><\/p>\n<p>\u3053\u306e\u6bd4\u8f03\u7684\u5c0f\u3055\u306a\u8ffd\u52a0\u306b\u3088\u308a\u3001\u4ed6\u306e\u30ea\u30dd\u30b8\u30c8\u30ea\u304b\u3089\u8ffd\u52a0\u3055\u308c\u305f\u5168\u30d5\u30a9\u30eb\u30c0\u30fc\u306e\u4e00\u89a7\u3092\u8868\u793a\u3059\u308b\u65b0\u3057\u3044 <tt>subtree<\/tt> \u30b3\u30de\u30f3\u30c9\u3092\u5b9f\u88c5\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u308b\u3088\u3046\u306b\u306a\u308a\u307e\u3057\u305f:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/aatljapan.wpengine.com\/files\/Screen-Shot-2015-09-02-at-2.16.46-PM.png\" alt=\"Screen Shot 2015-09-02 at 2.16.46 PM\" width=\"642\" height=\"33\" class=\"aligncenter size-full wp-image-3130\" srcset=\"https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.16.46-PM.png 642w, https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.16.46-PM-300x15.png 300w\" sizes=\"auto, (max-width: 642px) 100vw, 642px\" \/><\/p>\n<p>\u51fa\u529b\u306f\u3053\u306e\u3088\u3046\u306b\u306a\u308a\u307e\u3059:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/aatljapan.wpengine.com\/files\/Screen-Shot-2015-09-02-at-2.17.38-PM.png\" alt=\"Screen Shot 2015-09-02 at 2.17.38 PM\" width=\"642\" height=\"32\" class=\"aligncenter size-full wp-image-3131\" srcset=\"https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.17.38-PM.png 642w, https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.17.38-PM-300x15.png 300w\" sizes=\"auto, (max-width: 642px) 100vw, 642px\" \/><\/p>\n<p>\u305d\u3057\u3066\u518d\u5ea6 <tt>sha-1<\/tt> \u3092 <tt>ref<\/tt> \u306b\u95a2\u9023\u3065\u3051\u308b\u305f\u3081\u306b <tt>git ls-remote<\/tt> \u3092\u4f7f\u7528\u3067\u304d\u307e\u3059:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/aatljapan.wpengine.com\/files\/Screen-Shot-2015-09-02-at-2.18.13-PM.png\" alt=\"Screen Shot 2015-09-02 at 2.18.13 PM\" width=\"644\" height=\"32\" class=\"aligncenter size-full wp-image-3132\" srcset=\"https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.18.13-PM.png 644w, https:\/\/aatljapan.wpengine.com\/wp-content\/uploads\/Screen-Shot-2015-09-02-at-2.18.13-PM-300x15.png 300w\" sizes=\"auto, (max-width: 644px) 100vw, 644px\" \/><\/p>\n<p>\u4ee5\u4e0a\u306f<em>\u73fe\u5728\u4f5c\u6210\u4e2d<\/em>\u3067\u3059\u304c\u3001<a href=\"https:\/\/bitbucket.org\/durdn\/git\/branch\/np\/git-subtree-repo-support\">\u79c1\u306e Git fork<\/a> \u304b\u3089\u8a66\u3059\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002<\/p>\n<h2 id=\"conclusions\">\u307e\u3068\u3081<\/h2>\n<p>\u3053\u306e\u5909\u66f4\u306b\u5bfe\u3059\u308b\u9069\u6b63\u304b\u3064\u53b3\u683c\u306a\u30c6\u30b9\u30c8\u304c\u7d42\u308f\u308a\u6b21\u7b2c\u3001git \u306e\u30e1\u30fc\u30ea\u30f3\u30b0\u30ea\u30b9\u30c8\u306b\u30d1\u30c3\u30c1\u3092\u6295\u7a3f\u3057\u3001\u3053\u308c\u304c\u6709\u76ca\u3068\u5224\u65ad\u3055\u308c\u308b\u304b\u3069\u3046\u304b\u3092\u78ba\u8a8d\u3059\u308b\u4e88\u5b9a\u3067\u3059\u3002\u304d\u3063\u3068\u5927\u4e08\u592b\u3067\u3057\u3087\u3046! \u3068\u306b\u304b\u304f\u7686\u3055\u3093\u304c\u3053\u306e\u30d6\u30ed\u30b0\u8a18\u4e8b\u3092\u697d\u3057\u3093\u3067\u9802\u3051\u305f\u3089\u5e78\u3044\u3067\u3059\u3002Git \u306b\u3064\u3044\u3066\u3082\u3063\u3068\u8208\u5473\u304c\u3042\u308a\u307e\u3057\u305f\u3089\u3001\u79c1 <a href=\"http:\/\/twitter.com\/durdn\">@durdn<\/a> \u3084 <a href=\"http:\/\/twitter.com\/atlassiandev\">@atlassiandev<\/a> \u306b\u304a\u77e5\u3089\u305b\u4e0b\u3055\u3044\u3002<\/p>\n<p><em> 6 \u6708 9 \u65e5\u301c 11 \u65e5\u306b\u30d7\u30e9\u30cf\u3067\u958b\u50ac\u3055\u308c\u308b <a href=\"http:\/\/atlascamp.com\/\">AtlasCamp<\/a> \u3067 <a href=\"..\/..\/..\/authors\/npaolucci\/\">Nicola Paolucci<\/a> \u306e\u8b1b\u6f14\u3092\u3054\u89a7\u4e0b\u3055\u3044\u3002\u4e00\u7dd2\u306b\u30d3\u30fc\u30eb\u3092\u98f2\u307f\u307e\u3057\u3087\u3046\u3002<\/em><\/p>\n<p><\/br><br \/>\n<small>*\u672c\u30d6\u30ed\u30b0\u306f Atlassian Developers \u306e\u7ffb\u8a33\u3067\u3059\u3002\u672c\u6587\u4e2d\u306e\u65e5\u6642\u306a\u3069\u306f\u6295\u7a3f\u5f53\u6642\u306e\u3082\u306e\u3067\u3059\u306e\u3067\u3054\u4e86\u627f\u304f\u3060\u3055\u3044\u3002<br \/>\n*\u539f\u6587 : 2015 \u5e74 5 \u6708 18 \u65e5 \"<a href=\"https:\/\/developer.atlassian.com\/blog\/2015\/05\/the-power-of-git-subtree\/\" target=\"_blank\">The power of Git subtree<\/a>\"<\/small><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Git subtree \u3092\u4f7f\u3046\u3068\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u4ed6\u306e\u30ea\u30dd\u30b8\u30c8\u30ea\u306e\u30b5\u30d6\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3068\u3057\u3066\u8ffd\u52a0\u3059\u308b\u3053\u3068\u304c\u3067\u304d\u307e\u3059\u3002Git \u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u304c\u30d7\u30ed\u30b8\u30a7\u30af\u30c8\u4f9d\u5b58\u95a2\u4fc2\u3092\u7ba1\u7406\u3059\u308b\u65b9\u6cd5\u306f\u3044\u304f\u3064\u304b\u3042\u308a\u307e\u3059&hellip;<\/p>\n","protected":false},"author":275,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"bitbucket_subtitle":"","footnotes":""},"categories":[1],"tags":[103,369,543],"coauthors":[],"class_list":["post-3117","post","type-post","status-publish","format-standard","hentry","category-uncategorized","tag-git","tag-subtree","tag-vim"],"acf":[],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.atlassian.com\/ja\/blog\/wp-json\/wp\/v2\/posts\/3117","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.atlassian.com\/ja\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.atlassian.com\/ja\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.atlassian.com\/ja\/blog\/wp-json\/wp\/v2\/users\/275"}],"replies":[{"embeddable":true,"href":"https:\/\/www.atlassian.com\/ja\/blog\/wp-json\/wp\/v2\/comments?post=3117"}],"version-history":[{"count":0,"href":"https:\/\/www.atlassian.com\/ja\/blog\/wp-json\/wp\/v2\/posts\/3117\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.atlassian.com\/ja\/blog\/wp-json\/wp\/v2\/media?parent=3117"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.atlassian.com\/ja\/blog\/wp-json\/wp\/v2\/categories?post=3117"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.atlassian.com\/ja\/blog\/wp-json\/wp\/v2\/tags?post=3117"},{"taxonomy":"author","embeddable":true,"href":"https:\/\/www.atlassian.com\/ja\/blog\/wp-json\/wp\/v2\/coauthors?post=3117"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}