| 1 |
|
| 2 |
<!DOCTYPE html> |
| 3 |
|
| 4 |
|
| 5 |
<html lang="ja" data-content_root="../../" > |
| 6 |
|
| 7 |
<head> |
| 8 |
<meta charset="utf-8" /> |
| 9 |
<meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="viewport" content="width=device-width, initial-scale=1" /> |
| 10 |
|
| 11 |
<title>12.2.1. 導入 — Groonga v16.0.9ドキュメント</title> |
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
<script data-cfasync="false"> |
| 16 |
document.documentElement.dataset.mode = localStorage.getItem("mode") || ""; |
| 17 |
document.documentElement.dataset.theme = localStorage.getItem("theme") || ""; |
| 18 |
</script> |
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
<noscript> |
| 23 |
<style> |
| 24 |
.pst-js-only { display: none !important; } |
| 25 |
|
| 26 |
</style> |
| 27 |
</noscript> |
| 28 |
|
| 29 |
|
| 30 |
<link href="../../_static/styles/theme.css?digest=90905a2f556bf617f1a9" rel="stylesheet" /> |
| 31 |
<link href="../../_static/styles/pydata-sphinx-theme.css?digest=90905a2f556bf617f1a9" rel="stylesheet" /> |
| 32 |
|
| 33 |
<link rel="stylesheet" type="text/css" href="../../_static/pygments.css?v=8f2a1f02" /> |
| 34 |
|
| 35 |
|
| 36 |
<script defer src="../../_static/scripts/fontawesome.js?digest=90905a2f556bf617f1a9"></script> |
| 37 |
|
| 38 |
<link rel="preload" as="script" href="../../_static/scripts/bootstrap.js?digest=90905a2f556bf617f1a9" /> |
| 39 |
<link rel="preload" as="script" href="../../_static/scripts/pydata-sphinx-theme.js?digest=90905a2f556bf617f1a9" /> |
| 40 |
|
| 41 |
<script src="../../_static/documentation_options.js?v=1e3c191b"></script> |
| 42 |
<script src="../../_static/doctools.js?v=fd6eb6e6"></script> |
| 43 |
<script src="../../_static/sphinx_highlight.js?v=6ffebe34"></script> |
| 44 |
<script src="../../_static/translations.js?v=4755f45a"></script> |
| 45 |
<script> |
| 46 |
window.dataLayer = window.dataLayer || []; |
| 47 |
function gtag(){ dataLayer.push(arguments); } |
| 48 |
gtag('consent', 'default', { |
| 49 |
'ad_storage': 'denied', |
| 50 |
'ad_user_data': 'denied', |
| 51 |
'ad_personalization': 'denied', |
| 52 |
'analytics_storage': 'denied' |
| 53 |
}); |
| 54 |
</script> |
| 55 |
<script async="async" src="https://www.googletagmanager.com/gtag/js?id=G-MDK38RHNPW"></script> |
| 56 |
<script> |
| 57 |
window.dataLayer = window.dataLayer || []; |
| 58 |
function gtag(){dataLayer.push(arguments);} |
| 59 |
gtag('js', new Date()); |
| 60 |
gtag('config', 'G-MDK38RHNPW'); |
| 61 |
</script> |
| 62 |
<script>DOCUMENTATION_OPTIONS.pagename = 'contribution/documentation/introduction';</script> |
| 63 |
<script> |
| 64 |
DOCUMENTATION_OPTIONS.theme_version = '0.20.0'; |
| 65 |
DOCUMENTATION_OPTIONS.theme_switcher_json_url = 'https://groonga.org/docs/_static/switcher.json'; |
| 66 |
DOCUMENTATION_OPTIONS.theme_switcher_version_match = 'japanese'; |
| 67 |
DOCUMENTATION_OPTIONS.show_version_warning_banner = |
| 68 |
false; |
| 69 |
</script> |
| 70 |
<script>DOCUMENTATION_OPTIONS.search_as_you_type = false;</script> |
| 71 |
<link rel="icon" href="../../_static/favicon.ico"/> |
| 72 |
<link rel="index" title="索引" href="../../genindex.html" /> |
| 73 |
<link rel="search" title="検索" href="../../search.html" /> |
| 74 |
<link rel="next" title="12.2.2. 国際化" href="i18n.html" /> |
| 75 |
<link rel="prev" title="12.2. ドキュメント関連のコントリビュート方法" href="../documentation.html" /> |
| 76 |
<meta name="viewport" content="width=device-width, initial-scale=1"/> |
| 77 |
<meta name="docsearch:language" content="ja"/> |
| 78 |
<meta name="docsearch:version" content="16.0.9" /> |
| 79 |
|
| 80 |
|
| 81 |
<script src="../../_static/searchtools.js"></script> |
| 82 |
<script src="../../_static/language_data.js"></script> |
| 83 |
<script src="../../searchindex.js"></script> |
| 84 |
|
| 85 |
</head> |
| 86 |
<body data-default-mode=""> |
| 87 |
|
| 88 |
|
| 89 |
<div id="pst-skip-link" class="skip-link d-print-none"><a href="#main-content">本文へスキップ</a></div> |
| 90 |
|
| 91 |
|
| 92 |
<div id="pst-scroll-pixel-helper"></div> |
| 93 |
|
| 94 |
<button type="button" class="btn rounded-pill" id="pst-back-to-top"> |
| 95 |
<i class="fa-solid fa-arrow-up"></i>トップに戻る</button> |
| 96 |
|
| 97 |
|
| 98 |
|
| 99 |
|
| 100 |
<dialog id="pst-search-dialog"> |
| 101 |
|
| 102 |
<form class="bd-search d-flex align-items-center" |
| 103 |
action="../../search.html" |
| 104 |
method="get"> |
| 105 |
<i class="fa-solid fa-magnifying-glass"></i> |
| 106 |
<input type="search" |
| 107 |
class="form-control" |
| 108 |
name="q" |
| 109 |
placeholder="Search the docs ..." |
| 110 |
aria-label="Search the docs ..." |
| 111 |
autocomplete="off" |
| 112 |
autocorrect="off" |
| 113 |
autocapitalize="off" |
| 114 |
spellcheck="false"/> |
| 115 |
<span class="search-button__kbd-shortcut"><kbd class="kbd-shortcut__modifier">Ctrl</kbd>+<kbd>K</kbd></span> |
| 116 |
</form> |
| 117 |
</dialog> |
| 118 |
|
| 119 |
<div class="pst-async-banner-revealer d-none"> |
| 120 |
<aside id="bd-header-version-warning" class="d-none d-print-none" aria-label="バージョン警告"></aside> |
| 121 |
</div> |
| 122 |
|
| 123 |
|
| 124 |
<header id="pst-header" class="bd-header navbar navbar-expand-lg bd-navbar d-print-none"> |
| 125 |
<div class="bd-header__inner bd-page-width"> |
| 126 |
<button class="pst-navbar-icon sidebar-toggle primary-toggle" aria-label="サイトナビゲーション"> |
| 127 |
<span class="fa-solid fa-bars"></span> |
| 128 |
</button> |
| 129 |
|
| 130 |
|
| 131 |
<div class="col-lg-3 navbar-header-items__start"> |
| 132 |
|
| 133 |
<div class="navbar-item"> |
| 134 |
|
| 135 |
|
| 136 |
|
| 137 |
|
| 138 |
|
| 139 |
<a class="navbar-brand logo" href="https://groonga.org/ja/"> |
| 140 |
|
| 141 |
|
| 142 |
|
| 143 |
|
| 144 |
|
| 145 |
|
| 146 |
|
| 147 |
|
| 148 |
|
| 149 |
|
| 150 |
<img src="../../_static/groonga.png" class="logo__image only-light" alt="Groonga v16.0.9ドキュメント - Home"/> |
| 151 |
<img src="../../_static/groonga.png" class="logo__image only-dark pst-js-only" alt="Groonga v16.0.9ドキュメント - Home"/> |
| 152 |
|
| 153 |
|
| 154 |
</a></div> |
| 155 |
|
| 156 |
</div> |
| 157 |
|
| 158 |
<div class="col-lg-9 navbar-header-items"> |
| 159 |
|
| 160 |
|
| 161 |
<div class="navbar-header-items__end"> |
| 162 |
|
| 163 |
<div class="navbar-item navbar-persistent--container"> |
| 164 |
|
| 165 |
|
| 166 |
<button class="btn search-button-field search-button__button pst-js-only" title="検索" aria-label="検索" data-bs-placement="bottom" data-bs-toggle="tooltip"> |
| 167 |
<i class="fa-solid fa-magnifying-glass"></i> |
| 168 |
<span class="search-button__default-text">検索</span> |
| 169 |
<span class="search-button__kbd-shortcut"><kbd class="kbd-shortcut__modifier">Ctrl</kbd>+<kbd class="kbd-shortcut__modifier">K</kbd></span> |
| 170 |
</button> |
| 171 |
</div> |
| 172 |
|
| 173 |
|
| 174 |
<div class="navbar-item"> |
| 175 |
|
| 176 |
<div class="theme-switch-container dropdown pst-js-only" data-bs-toggle="tooltip" data-bs-placement="bottom" title="Color mode"> |
| 177 |
<button class="btn btn-sm nav-link pst-navbar-icon theme-switch-button dropdown-toggle" aria-label="Color mode" data-bs-toggle="dropdown"> |
| 178 |
<i class="theme-switch fa-solid fa-sun fa-lg fa-fw" data-mode="light" title="ライト"></i> |
| 179 |
<i class="theme-switch fa-solid fa-moon fa-lg fa-fw" data-mode="dark" title="ダーク"></i> |
| 180 |
<i class="theme-switch fa-solid fa-circle-half-stroke fa-lg fa-fw" data-mode="auto" title="System Settings"></i> |
| 181 |
</button> |
| 182 |
<ul class="dropdown-menu dropdown-menu-end"> |
| 183 |
<li><button class="dropdown-item d-flex align-items-center theme-change-button" data-mode="auto"><i class="fa-solid fa-circle-half-stroke fa-lg fa-fw me-1"></i>System Settings</button></li> |
| 184 |
<li><button class="dropdown-item d-flex align-items-center theme-change-button" data-mode="light"><i class="fa-solid fa-sun fa-lg fa-fw me-1"></i>ライト</button></li> |
| 185 |
<li><button class="dropdown-item d-flex align-items-center theme-change-button" data-mode="dark"><i class="fa-solid fa-moon fa-lg fa-fw me-1"></i>ダーク</button></li> |
| 186 |
</ul> |
| 187 |
</div></div> |
| 188 |
|
| 189 |
<div class="navbar-item"><ul class="navbar-icon-links" |
| 190 |
aria-label="Icon Links"> |
| 191 |
<li class="nav-item"> |
| 192 |
|
| 193 |
|
| 194 |
|
| 195 |
|
| 196 |
|
| 197 |
|
| 198 |
|
| 199 |
|
| 200 |
<a href="https://github.com/groonga/groonga" title="GitHub" class="nav-link pst-navbar-icon" rel="noopener" target="_blank" data-bs-toggle="tooltip" data-bs-placement="bottom"><i class="fa-brands fa-square-github fa-lg" aria-hidden="true"></i><span class="visually-hidden">GitHub</span></a> |
| 201 |
</li> |
| 202 |
<li class="nav-item"> |
| 203 |
|
| 204 |
|
| 205 |
|
| 206 |
|
| 207 |
|
| 208 |
|
| 209 |
|
| 210 |
|
| 211 |
<a href="https://twitter.com/groonga" title="Twitter" class="nav-link pst-navbar-icon" rel="noopener" target="_blank" data-bs-toggle="tooltip" data-bs-placement="bottom"><i class="fa-brands fa-square-twitter fa-lg" aria-hidden="true"></i><span class="visually-hidden">Twitter</span></a> |
| 212 |
</li> |
| 213 |
<li class="nav-item"> |
| 214 |
|
| 215 |
|
| 216 |
|
| 217 |
|
| 218 |
|
| 219 |
|
| 220 |
|
| 221 |
|
| 222 |
<a href="/ja/blog" title="Blog" class="nav-link pst-navbar-icon" rel="noopener" target="_blank" data-bs-toggle="tooltip" data-bs-placement="bottom"><i class="fas fa-blog fa-lg" aria-hidden="true"></i><span class="visually-hidden">Blog</span></a> |
| 223 |
</li> |
| 224 |
</ul></div> |
| 225 |
|
| 226 |
<div class="navbar-item"> |
| 227 |
<div class="version-switcher__container dropdown pst-js-only"> |
| 228 |
<button id="pst-version-switcher-button-2" |
| 229 |
type="button" |
| 230 |
class="version-switcher__button btn btn-sm dropdown-toggle" |
| 231 |
data-bs-toggle="dropdown" |
| 232 |
aria-haspopup="listbox" |
| 233 |
aria-controls="pst-version-switcher-list-2" |
| 234 |
aria-label="Version switcher list" |
| 235 |
> |
| 236 |
Choose version |
| 237 |
<span class="caret"></span> |
| 238 |
</button> |
| 239 |
<div id="pst-version-switcher-list-2" |
| 240 |
class="version-switcher__menu dropdown-menu list-group-flush py-0" |
| 241 |
role="listbox" aria-labelledby="pst-version-switcher-button-2"> |
| 242 |
|
| 243 |
</div> |
| 244 |
</div></div> |
| 245 |
|
| 246 |
</div> |
| 247 |
|
| 248 |
</div> |
| 249 |
|
| 250 |
|
| 251 |
<div class="navbar-persistent--mobile"> |
| 252 |
|
| 253 |
<button class="btn search-button-field search-button__button pst-js-only" title="検索" aria-label="検索" data-bs-placement="bottom" data-bs-toggle="tooltip"> |
| 254 |
<i class="fa-solid fa-magnifying-glass"></i> |
| 255 |
<span class="search-button__default-text">検索</span> |
| 256 |
<span class="search-button__kbd-shortcut"><kbd class="kbd-shortcut__modifier">Ctrl</kbd>+<kbd class="kbd-shortcut__modifier">K</kbd></span> |
| 257 |
</button> |
| 258 |
</div> |
| 259 |
|
| 260 |
|
| 261 |
|
| 262 |
<button class="pst-navbar-icon sidebar-toggle secondary-toggle" aria-label="このページでは"> |
| 263 |
<span class="fa-solid fa-outdent"></span> |
| 264 |
</button> |
| 265 |
|
| 266 |
</div> |
| 267 |
|
| 268 |
</header> |
| 269 |
|
| 270 |
|
| 271 |
<div class="bd-container"> |
| 272 |
<div class="bd-container__inner bd-page-width"> |
| 273 |
|
| 274 |
|
| 275 |
|
| 276 |
<dialog id="pst-primary-sidebar-modal"></dialog> |
| 277 |
<div id="pst-primary-sidebar" class="bd-sidebar-primary bd-sidebar"> |
| 278 |
|
| 279 |
|
| 280 |
|
| 281 |
<div class="sidebar-header-items sidebar-primary__section"> |
| 282 |
|
| 283 |
|
| 284 |
|
| 285 |
|
| 286 |
<div class="sidebar-header-items__end"> |
| 287 |
|
| 288 |
<div class="navbar-item"> |
| 289 |
|
| 290 |
<div class="theme-switch-container dropdown pst-js-only" data-bs-toggle="tooltip" data-bs-placement="bottom" title="Color mode"> |
| 291 |
<button class="btn btn-sm nav-link pst-navbar-icon theme-switch-button dropdown-toggle" aria-label="Color mode" data-bs-toggle="dropdown"> |
| 292 |
<i class="theme-switch fa-solid fa-sun fa-lg fa-fw" data-mode="light" title="ライト"></i> |
| 293 |
<i class="theme-switch fa-solid fa-moon fa-lg fa-fw" data-mode="dark" title="ダーク"></i> |
| 294 |
<i class="theme-switch fa-solid fa-circle-half-stroke fa-lg fa-fw" data-mode="auto" title="System Settings"></i> |
| 295 |
</button> |
| 296 |
<ul class="dropdown-menu dropdown-menu-end"> |
| 297 |
<li><button class="dropdown-item d-flex align-items-center theme-change-button" data-mode="auto"><i class="fa-solid fa-circle-half-stroke fa-lg fa-fw me-1"></i>System Settings</button></li> |
| 298 |
<li><button class="dropdown-item d-flex align-items-center theme-change-button" data-mode="light"><i class="fa-solid fa-sun fa-lg fa-fw me-1"></i>ライト</button></li> |
| 299 |
<li><button class="dropdown-item d-flex align-items-center theme-change-button" data-mode="dark"><i class="fa-solid fa-moon fa-lg fa-fw me-1"></i>ダーク</button></li> |
| 300 |
</ul> |
| 301 |
</div></div> |
| 302 |
|
| 303 |
<div class="navbar-item"><ul class="navbar-icon-links" |
| 304 |
aria-label="Icon Links"> |
| 305 |
<li class="nav-item"> |
| 306 |
|
| 307 |
|
| 308 |
|
| 309 |
|
| 310 |
|
| 311 |
|
| 312 |
|
| 313 |
|
| 314 |
<a href="https://github.com/groonga/groonga" title="GitHub" class="nav-link pst-navbar-icon" rel="noopener" target="_blank" data-bs-toggle="tooltip" data-bs-placement="bottom"><i class="fa-brands fa-square-github fa-lg" aria-hidden="true"></i><span class="visually-hidden">GitHub</span></a> |
| 315 |
</li> |
| 316 |
<li class="nav-item"> |
| 317 |
|
| 318 |
|
| 319 |
|
| 320 |
|
| 321 |
|
| 322 |
|
| 323 |
|
| 324 |
|
| 325 |
<a href="https://twitter.com/groonga" title="Twitter" class="nav-link pst-navbar-icon" rel="noopener" target="_blank" data-bs-toggle="tooltip" data-bs-placement="bottom"><i class="fa-brands fa-square-twitter fa-lg" aria-hidden="true"></i><span class="visually-hidden">Twitter</span></a> |
| 326 |
</li> |
| 327 |
<li class="nav-item"> |
| 328 |
|
| 329 |
|
| 330 |
|
| 331 |
|
| 332 |
|
| 333 |
|
| 334 |
|
| 335 |
|
| 336 |
<a href="/ja/blog" title="Blog" class="nav-link pst-navbar-icon" rel="noopener" target="_blank" data-bs-toggle="tooltip" data-bs-placement="bottom"><i class="fas fa-blog fa-lg" aria-hidden="true"></i><span class="visually-hidden">Blog</span></a> |
| 337 |
</li> |
| 338 |
</ul></div> |
| 339 |
|
| 340 |
<div class="navbar-item"> |
| 341 |
<div class="version-switcher__container dropdown pst-js-only"> |
| 342 |
<button id="pst-version-switcher-button-3" |
| 343 |
type="button" |
| 344 |
class="version-switcher__button btn btn-sm dropdown-toggle" |
| 345 |
data-bs-toggle="dropdown" |
| 346 |
aria-haspopup="listbox" |
| 347 |
aria-controls="pst-version-switcher-list-3" |
| 348 |
aria-label="Version switcher list" |
| 349 |
> |
| 350 |
Choose version |
| 351 |
<span class="caret"></span> |
| 352 |
</button> |
| 353 |
<div id="pst-version-switcher-list-3" |
| 354 |
class="version-switcher__menu dropdown-menu list-group-flush py-0" |
| 355 |
role="listbox" aria-labelledby="pst-version-switcher-button-3"> |
| 356 |
|
| 357 |
</div> |
| 358 |
</div></div> |
| 359 |
|
| 360 |
</div> |
| 361 |
|
| 362 |
</div> |
| 363 |
|
| 364 |
<div class="sidebar-primary-items__start sidebar-primary__section"> |
| 365 |
<div class="sidebar-primary-item pst-sidebar-collapse"><button id="pst-collapse-sidebar-button" aria-expanded="true" aria-controls="pst-primary-sidebar"> |
| 366 |
<svg class="pst-icon" role="img" aria-hidden="true" focusable="false" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"> |
| 367 |
<path fill="currentColor" d="M3 15.5C2.36232 15.5 1.74874 15.2564 1.28478 14.8189C0.820828 14.3815 0.541576 13.7832 0.504167 13.1467L0.5 13L0.5 3C0.499965 2.36232 0.743605 1.74874 1.18107 1.28478C1.61854 0.820828 2.21676 0.541576 2.85333 0.504167L3 0.5L13 0.5C13.6377 0.499965 14.2513 0.743605 14.7152 1.18107C15.1792 1.61854 15.4584 2.21676 15.4958 2.85333L15.5 3L15.5 13C15.5 13.6377 15.2564 14.2513 14.8189 14.7152C14.3815 15.1792 13.7832 15.4584 13.1467 15.4958L13 15.5L3 15.5ZM3 13.8333L10.5 13.8333L10.5 2.16667L3 2.16667C2.79589 2.16669 2.59889 2.24163 2.44636 2.37726C2.29383 2.5129 2.19638 2.69979 2.1725 2.9025L2.16667 3L2.16667 13C2.16669 13.2041 2.24163 13.4011 2.37726 13.5536C2.5129 13.7062 2.69979 13.8036 2.9025 13.8275L3 13.8333ZM6.65583 10.325L6.5775 10.2558L4.91083 8.58917C4.76735 8.44567 4.68116 8.25476 4.66843 8.05223C4.65569 7.84971 4.71729 7.6495 4.84167 7.48917L4.91083 7.41083L6.5775 5.74417C6.72747 5.59471 6.9287 5.50794 7.14032 5.50148C7.35194 5.49502 7.55809 5.56935 7.7169 5.70937C7.8757 5.8494 7.97525 6.04463 7.99533 6.25539C8.01541 6.46616 7.95451 6.67667 7.825 6.84417L7.75583 6.9225L6.67917 8L7.75583 9.0775C7.89931 9.22099 7.98551 9.41191 7.99824 9.61443C8.01097 9.81695 7.94938 10.0172 7.825 10.1775L7.75583 10.2558C7.61234 10.3993 7.42142 10.4855 7.2189 10.4982C7.01638 10.511 6.81617 10.4494 6.65583 10.325Z"/> |
| 368 |
</svg> |
| 369 |
<span class="pst-collapse-sidebar-label">Collapse Sidebar</span> |
| 370 |
<span class="pst-expand-sidebar-label">Expand Sidebar</span> |
| 371 |
</button></div> |
| 372 |
<div class="sidebar-primary-item"> |
| 373 |
|
| 374 |
<nav class="bd-docs-nav bd-links" |
| 375 |
aria-label="セクションナビゲーション"> |
| 376 |
<p class="bd-links__title" role="heading" aria-level="1">セクションナビゲーション</p> |
| 377 |
<div class="bd-toc-item navbar-nav"><ul class="current nav bd-sidenav"> |
| 378 |
<li class="toctree-l1"><a class="reference internal" href="../report.html">12.1. バグレポートの送り方</a></li> |
| 379 |
<li class="toctree-l1 current active has-children"><a class="reference internal" href="../documentation.html">12.2. ドキュメント関連のコントリビュート方法</a><details open="open"><summary><span class="toctree-toggle" role="presentation"><i class="fa-solid fa-chevron-down"></i></span></summary><ul class="current"> |
| 380 |
<li class="toctree-l2 current active"><a class="current reference internal" href="#">12.2.1. 導入</a></li> |
| 381 |
<li class="toctree-l2"><a class="reference internal" href="i18n.html">12.2.2. 国際化</a></li> |
| 382 |
<li class="toctree-l2"><a class="reference internal" href="c-api.html">12.2.3. C API</a></li> |
| 383 |
</ul> |
| 384 |
</details></li> |
| 385 |
<li class="toctree-l1 has-children"><a class="reference internal" href="../development.html">12.3. Groonga開発者向け情報</a><details open="open"><summary><span class="toctree-toggle" role="presentation"><i class="fa-solid fa-chevron-down"></i></span></summary><ul> |
| 386 |
<li class="toctree-l2"><a class="reference internal" href="../development/repository.html">12.3.1. リポジトリ</a></li> |
| 387 |
<li class="toctree-l2 has-children"><a class="reference internal" href="../development/build.html">12.3.2. リポジトリーのGroongaをビルドする方法</a><details><summary><span class="toctree-toggle" role="presentation"><i class="fa-solid fa-chevron-down"></i></span></summary><ul> |
| 388 |
<li class="toctree-l3"><a class="reference internal" href="../development/build/unix_cmake.html">12.3.2.1. GNU/LinuxまたはUnix上でCMakeを使ってリポジトリーのGroongaをビルドする方法</a></li> |
| 389 |
<li class="toctree-l3"><a class="reference internal" href="../development/build/windows_cmake.html">12.3.2.2. Windows上でCMakeを使ってリポジトリーのGroongaをビルドする方法</a></li> |
| 390 |
</ul> |
| 391 |
</details></li> |
| 392 |
<li class="toctree-l2"><a class="reference internal" href="../development/com.html">12.3.3. Groonga 通信アーキテクチャ</a></li> |
| 393 |
<li class="toctree-l2"><a class="reference internal" href="../development/cooperation.html">12.3.4. ユーザーと協力して開発をうまく進めていくための指針</a></li> |
| 394 |
<li class="toctree-l2"><a class="reference internal" href="../development/query.html">12.3.5. クエリの実現</a></li> |
| 395 |
|
| 396 |
<li class="toctree-l2"><a class="reference internal" href="../development/release.html">12.3.7. リリース手順</a></li> |
| 397 |
<li class="toctree-l2"><a class="reference internal" href="../development/test.html">12.3.8. テスト方法</a></li> |
| 398 |
</ul> |
| 399 |
</details></li> |
| 400 |
</ul> |
| 401 |
</div> |
| 402 |
</nav></div> |
| 403 |
</div> |
| 404 |
|
| 405 |
|
| 406 |
<div class="sidebar-primary-items__end sidebar-primary__section"> |
| 407 |
<div class="sidebar-primary-item"> |
| 408 |
<div id="ethical-ad-placement" |
| 409 |
class="flat" |
| 410 |
data-ea-publisher="readthedocs" |
| 411 |
data-ea-type="readthedocs-sidebar" |
| 412 |
data-ea-manual="true"> |
| 413 |
</div></div> |
| 414 |
</div> |
| 415 |
|
| 416 |
|
| 417 |
</div> |
| 418 |
|
| 419 |
<main id="main-content" class="bd-main" role="main"> |
| 420 |
|
| 421 |
|
| 422 |
<div class="bd-content"> |
| 423 |
<div class="bd-article-container"> |
| 424 |
|
| 425 |
<div class="bd-header-article d-print-none"> |
| 426 |
<div class="header-article-items header-article__inner"> |
| 427 |
|
| 428 |
<div class="header-article-items__start"> |
| 429 |
|
| 430 |
<div class="header-article-item"> |
| 431 |
|
| 432 |
<nav aria-label="パンくずリスト" class="d-print-none"> |
| 433 |
<ul class="bd-breadcrumbs"> |
| 434 |
|
| 435 |
<li class="breadcrumb-item breadcrumb-home"> |
| 436 |
<a href="../../index.html" class="nav-link" aria-label="ホーム"> |
| 437 |
<i class="fa-solid fa-home"></i> |
| 438 |
</a> |
| 439 |
</li> |
| 440 |
|
| 441 |
<li class="breadcrumb-item"><a href="../../contribution.html" class="nav-link"><span class="section-number">12. </span>Groongaへのコントリビュート方法</a></li> |
| 442 |
|
| 443 |
|
| 444 |
<li class="breadcrumb-item"><a href="../documentation.html" class="nav-link"><span class="section-number">12.2. </span>ドキュメント関連のコントリビュート方法</a></li> |
| 445 |
|
| 446 |
<li class="breadcrumb-item active" aria-current="page"><span class="ellipsis"><span class="section-number">12.2.1. </span>導入</span></li> |
| 447 |
</ul> |
| 448 |
</nav> |
| 449 |
</div> |
| 450 |
|
| 451 |
</div> |
| 452 |
|
| 453 |
|
| 454 |
</div> |
| 455 |
</div> |
| 456 |
|
| 457 |
|
| 458 |
|
| 459 |
|
| 460 |
<div id="searchbox"></div> |
| 461 |
<article class="bd-article"> |
| 462 |
|
| 463 |
<section class="tex2jax_ignore mathjax_ignore" id="introduction"> |
| 464 |
<h1><span class="section-number">12.2.1. </span>導入<a class="headerlink" href="#introduction" title="Link to this heading">#</a></h1> |
| 465 |
<p>このドキュメントは、Groongaドキュメントの執筆、生成、管理の手順について説明します。以下の手順で、Groongaドキュメントの向上や更新に貢献できます。</p> |
| 466 |
<section id="how-to-fork-and-clone-groonga-repository"> |
| 467 |
<h2><span class="section-number">12.2.1.1. </span>Groongaリポジトリをフォークしクローンする方法<a class="headerlink" href="#how-to-fork-and-clone-groonga-repository" title="Link to this heading">#</a></h2> |
| 468 |
<p>Groongaドキュメントへ貢献するには、まずはGroongaリポジトリをフォークしクローンするとこから始めます。そうすることで、あなたのリポジトリで個人的な変更や実験が可能になります。他にも、その成果をGroongaリポジトリにあなたの貢献として送ることもできます。まずは、次の手順に倣って、フォークとクローンをしてください。</p> |
| 469 |
<ol class="arabic simple"> |
| 470 |
<li><p>GitHubの <a class="github reference external" href="https://github.com/groonga/groonga">groonga/groonga</a> へ移動してください。</p></li> |
| 471 |
<li><p><code class="docutils literal notranslate"><span class="pre">Fork</span></code> ボタンをクリックして、Groongaリポジトリをフォークしてください。</p></li> |
| 472 |
<li><p>下記のコマンドでフォークしたGroongaリポジトリをクローンしてください。</p></li> |
| 473 |
</ol> |
| 474 |
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="gp">% </span>git<span class="w"> </span>clone<span class="w"> </span>--recursive<span class="w"> </span>[email protected]:<span class="si">${</span><span class="nv">YOUR_GITHUB_ACCOUNT</span><span class="si">}</span>/groonga.git |
| 475 |
</pre></div> |
| 476 |
</div> |
| 477 |
</section> |
| 478 |
<section id="install-dependent-software"> |
| 479 |
<h2><span class="section-number">12.2.1.2. </span>必要なソフトウェアのインストール<a class="headerlink" href="#install-dependent-software" title="Link to this heading">#</a></h2> |
| 480 |
<p>Groongaはドキュメントツールとして <a class="reference external" href="https://www.sphinx-doc.org/">Sphinx</a> を使います。</p> |
| 481 |
<p>以下はSphinxをインストールするコマンドラインです。</p> |
| 482 |
<p>Debian GNU/Linux, Ubuntu:</p> |
| 483 |
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="gp">% </span>./setup.sh |
| 484 |
<span class="gp">% </span>sudo<span class="w"> </span>pip<span class="w"> </span>install<span class="w"> </span>-r<span class="w"> </span>doc/requirements.txt |
| 485 |
<span class="gp">% </span><span class="o">(</span><span class="nb">cd</span><span class="w"> </span>doc<span class="w"> </span><span class="o">&&</span><span class="w"> </span>bundle<span class="w"> </span>install<span class="o">)</span> |
| 486 |
</pre></div> |
| 487 |
</div> |
| 488 |
<p>AlmaLinux, Fedora:</p> |
| 489 |
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="gp">% </span>sudo<span class="w"> </span>dnf<span class="w"> </span>install<span class="w"> </span>-y<span class="w"> </span>python-pip<span class="w"> </span>gettext |
| 490 |
<span class="gp">% </span>sudo<span class="w"> </span>pip<span class="w"> </span>install<span class="w"> </span>-r<span class="w"> </span>doc/requirements.txt |
| 491 |
<span class="gp">% </span><span class="o">(</span><span class="nb">cd</span><span class="w"> </span>doc<span class="w"> </span><span class="o">&&</span><span class="w"> </span>bundle<span class="w"> </span>install<span class="o">)</span> |
| 492 |
</pre></div> |
| 493 |
</div> |
| 494 |
<p>macOS:</p> |
| 495 |
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="gp">% </span>brew<span class="w"> </span>bundle |
| 496 |
<span class="gp">% </span><span class="nb">export</span><span class="w"> </span><span class="nv">PATH</span><span class="o">=</span><span class="k">$(</span>brew<span class="w"> </span>--prefix<span class="w"> </span>gettext<span class="k">)</span>/bin:<span class="nv">$PATH</span> |
| 497 |
<span class="gp">% </span>pip<span class="w"> </span>install<span class="w"> </span>-r<span class="w"> </span>doc/requirements.txt |
| 498 |
<span class="gp">% </span><span class="o">(</span><span class="nb">cd</span><span class="w"> </span>doc<span class="w"> </span><span class="o">&&</span><span class="w"> </span>bundle<span class="w"> </span>install<span class="o">)</span> |
| 499 |
</pre></div> |
| 500 |
</div> |
| 501 |
</section> |
| 502 |
<section id="run-cmake-with-preset-doc"> |
| 503 |
<h2><span class="section-number">12.2.1.3. </span><code class="docutils literal notranslate"><span class="pre">cmake</span></code> を <code class="docutils literal notranslate"><span class="pre">--preset=doc</span></code> 付きで実行<a class="headerlink" href="#run-cmake-with-preset-doc" title="Link to this heading">#</a></h2> |
| 504 |
<p>Groonga は、デフォルトではドキュメントの生成を無効化しています。 <code class="docutils literal notranslate"><span class="pre">cmake</span></code> に <code class="docutils literal notranslate"><span class="pre">--preset=doc</span></code> オプションを追加して明示的に有効にする必要があります。:</p> |
| 505 |
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="gp">% </span>cmake<span class="w"> </span>-S<span class="w"> </span>.<span class="w"> </span>-B<span class="w"> </span>../groonga.doc<span class="w"> </span>--preset<span class="o">=</span>doc |
| 506 |
</pre></div> |
| 507 |
</div> |
| 508 |
<p>これで、 Groonga ドキュメントをビルドする準備が出来ました。</p> |
| 509 |
</section> |
| 510 |
<section id="generate-html"> |
| 511 |
<h2><span class="section-number">12.2.1.4. </span>HTMLファイルを生成<a class="headerlink" href="#generate-html" title="Link to this heading">#</a></h2> |
| 512 |
<p>以下のコマンドでHTMLファイルを生成できます。:</p> |
| 513 |
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="gp">% </span>cmake<span class="w"> </span>--build<span class="w"> </span>../groonga.doc |
| 514 |
</pre></div> |
| 515 |
</div> |
| 516 |
<p>生成されたHTMLドキュメントは <code class="docutils literal notranslate"><span class="pre">../groonga.doc/doc/ja/html/</span></code> にあります。</p> |
| 517 |
</section> |
| 518 |
<section id="how-to-edit-documentation"> |
| 519 |
<h2><span class="section-number">12.2.1.5. </span>ドキュメントを編集する方法<a class="headerlink" href="#how-to-edit-documentation" title="Link to this heading">#</a></h2> |
| 520 |
<p>Groongaドキュメントは、<a class="reference external" href="https://www.sphinx-doc.org/en/master/usage/restructuredtext/index.html">reStructuredText (.rst)</a> または <a class="reference external" href="https://myst-parser.readthedocs.io/en/latest/">Markdown (.md)</a> で書かれています。Groongaドキュメントのファイルは、<code class="docutils literal notranslate"><span class="pre">doc/source</span></code> 配下にあります。それぞれのページに対応した <code class="docutils literal notranslate"><span class="pre">.rst</span></code> ファイルまたは、 <code class="docutils literal notranslate"><span class="pre">.md</span></code> が必ず1つあります。対応するファイルを変更することで、対象のドキュメントを編集できます。例えば、この <a class="reference internal" href="#"><span class="doc">導入</span></a> ページを編集したい場合は、<code class="docutils literal notranslate"><span class="pre">doc/source/contribution/documentation/introduction.rst</span></code> ファイルを編集すればよいです。編集したいファイルをみつけて、編集してください。</p> |
| 521 |
</section> |
| 522 |
<section id="how-to-add-a-new-documentation"> |
| 523 |
<span id="how-to-add-new-documentation"></span><h2><span class="section-number">12.2.1.6. </span>新しいドキュメントを追加する方法<a class="headerlink" href="#how-to-add-a-new-documentation" title="Link to this heading">#</a></h2> |
| 524 |
<p>新しいドキュメントを追加したい場合は、以下のコマンドで新しいドキュメントを <code class="docutils literal notranslate"><span class="pre">doc/files.am</span></code>と <code class="docutils literal notranslate"><span class="pre">doc/files.cmake</span></code> に追加する必要があります。</p> |
| 525 |
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="gp">$ </span>cmake<span class="w"> </span>-S<span class="w"> </span>.<span class="w"> </span>-B<span class="w"> </span>../groonga.doc<span class="w"> </span>--preset<span class="o">=</span>doc |
| 526 |
<span class="gp">$ </span>cmake<span class="w"> </span>--build<span class="w"> </span>../groonga.doc |
| 527 |
<span class="gp">$ </span>ninja<span class="w"> </span>doc_update_files<span class="w"> </span>-C<span class="w"> </span>../groonga.doc |
| 528 |
</pre></div> |
| 529 |
</div> |
| 530 |
<p>このケースでは、新しいドキュメントだけでなく、 <code class="docutils literal notranslate"><span class="pre">doc/files.am</span></code> と <code class="docutils literal notranslate"><span class="pre">doc/files.cmake</span></code> もコミットする必要があることに注意してください。</p> |
| 531 |
</section> |
| 532 |
<section id="preview-changes-on-html-files"> |
| 533 |
<h2><span class="section-number">12.2.1.7. </span>HTMLファイルで変更を確認する<a class="headerlink" href="#preview-changes-on-html-files" title="Link to this heading">#</a></h2> |
| 534 |
<p>HTML形式でドキュメントの変更をブラウザで確認できます。次の2つの手順に倣ってください。</p> |
| 535 |
<ol class="arabic simple"> |
| 536 |
<li><p>変更を反映したHTMLファイルを生成する</p></li> |
| 537 |
<li><p>Webブラウザで生成されたHTMLファイルを確認する</p></li> |
| 538 |
</ol> |
| 539 |
<section id="generate-the-html-files-with-your-changes"> |
| 540 |
<h3><span class="section-number">12.2.1.7.1. </span>変更を反映したHTMLファイルを生成する<a class="headerlink" href="#generate-the-html-files-with-your-changes" title="Link to this heading">#</a></h3> |
| 541 |
<p>次のコマンドで、変更を反映したHTMLファイルを生成します。生成されたファイルは、<code class="docutils literal notranslate"><span class="pre">../groonga.doc/doc/en/html/</span></code> 配下にあります。各 <code class="docutils literal notranslate"><span class="pre">.rst</span></code> または <code class="docutils literal notranslate"><span class="pre">.md</span></code> ファイルに対応するファイルが生成されています。</p> |
| 542 |
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="gp">% </span>cmake<span class="w"> </span>--build<span class="w"> </span>../groonga.doc |
| 543 |
</pre></div> |
| 544 |
</div> |
| 545 |
</section> |
| 546 |
<section id="preview-the-generated-html-files-in-your-web-browser"> |
| 547 |
<h3><span class="section-number">12.2.1.7.2. </span>Webブラウザで生成されたHTMLファイルを確認する<a class="headerlink" href="#preview-the-generated-html-files-in-your-web-browser" title="Link to this heading">#</a></h3> |
| 548 |
<p>生成されたファイルをWebブラウザで開き、変更を確認できます。例えば、この <a class="reference internal" href="#"><span class="doc">導入</span></a> ページを編集した場合、次のコマンドで変更を確認できます。</p> |
| 549 |
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="gp">% </span>open<span class="w"> </span>../groonga.doc/doc/en/html/contribution/documentation/introduction.html |
| 550 |
</pre></div> |
| 551 |
</div> |
| 552 |
</section> |
| 553 |
</section> |
| 554 |
<section id="send-patch"> |
| 555 |
<h2><span class="section-number">12.2.1.8. </span>パッチを送る<a class="headerlink" href="#send-patch" title="Link to this heading">#</a></h2> |
| 556 |
<p>GitHub上のGroongaリポジトリに対してプルリクエストを通じてパッチを送ることができます。次の手順で、気軽にプルリクエストを作ってみましょう。</p> |
| 557 |
<ul class="simple"> |
| 558 |
<li><p>フォーク先リポジトリでプレビューを有効にする(任意)</p></li> |
| 559 |
<li><p>プルリクエストの準備をする</p></li> |
| 560 |
<li><p>プルリクエストを送る</p></li> |
| 561 |
</ul> |
| 562 |
<section id="enable-preview-on-your-fork-optional"> |
| 563 |
<h3><span class="section-number">12.2.1.8.1. </span>フォーク先リポジトリでプレビューを有効にする(任意)<a class="headerlink" href="#enable-preview-on-your-fork-optional" title="Link to this heading">#</a></h3> |
| 564 |
<p>コミットをプッシュする前に、次の手順を実行することでフォークしたリポジトリ上でプレビューを有効にできます。</p> |
| 565 |
<ol class="arabic simple"> |
| 566 |
<li><p>フォークしたリポジトリで GitHub Pages を有効にする。</p> |
| 567 |
<ul class="simple"> |
| 568 |
<li><p><code class="docutils literal notranslate"><span class="pre">https://github.com/${YOUR_GITHUB_ACCOUNT}/groonga/settings/pages</span></code>を開く</p></li> |
| 569 |
<li><p>"Source"に"GitHub Actions"を選択する</p></li> |
| 570 |
</ul> |
| 571 |
</li> |
| 572 |
<li><p>フォークしたリポジトリのすべてのブランチからGitHub Pagesの公開を許可する。</p> |
| 573 |
<ul class="simple"> |
| 574 |
<li><p><code class="docutils literal notranslate"><span class="pre">https://github.com/${YOUR_GITHUB_ACCOUNT}/groonga/settings/environments</span></code>を開く</p></li> |
| 575 |
<li><p>"github-pages"環境を選択する</p></li> |
| 576 |
<li><p>デフォルトの"Deployment branches and tags"ルールを変更する</p> |
| 577 |
<ul> |
| 578 |
<li><p>"Edit"ボタンを押す</p></li> |
| 579 |
<li><p>"Name pattern"を<code class="docutils literal notranslate"><span class="pre">main</span></code>から<code class="docutils literal notranslate"><span class="pre">*</span></code>に変更する</p></li> |
| 580 |
</ul> |
| 581 |
</li> |
| 582 |
</ul> |
| 583 |
</li> |
| 584 |
</ol> |
| 585 |
<p>変更をpushしたあと、次のURLで変更内容をプレビューできます。</p> |
| 586 |
<ul class="simple"> |
| 587 |
<li><p><code class="docutils literal notranslate"><span class="pre">https://${YOUR_GITHUB_ACCOUNT}.github.io/groonga/</span></code></p></li> |
| 588 |
<li><p><code class="docutils literal notranslate"><span class="pre">https://${YOUR_GITHUB_ACCOUNT}.github.io/groonga/ja/</span></code></p></li> |
| 589 |
<li><p><code class="docutils literal notranslate"><span class="pre">https://${YOUR_GITHUB_ACCOUNT}.github.io/groonga/reference/api/</span></code></p></li> |
| 590 |
</ul> |
| 591 |
</section> |
| 592 |
<section id="prepare-your-pull-request"> |
| 593 |
<h3><span class="section-number">12.2.1.8.2. </span>プルリクエストの準備をする<a class="headerlink" href="#prepare-your-pull-request" title="Link to this heading">#</a></h3> |
| 594 |
<p>次のコマンドで、変更をコミットし、その変更をGitHubにある自分のフォークリポジトリにプッシュします。</p> |
| 595 |
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="gp">% </span>git<span class="w"> </span>switch<span class="w"> </span>-c<span class="w"> </span>your-working-branch |
| 596 |
<span class="gp">% </span>git<span class="w"> </span>add<span class="w"> </span>doc |
| 597 |
<span class="gp">% </span>git<span class="w"> </span>commit<span class="w"> </span>-m<span class="w"> </span><span class="s1">'Describe your works here'</span> |
| 598 |
<span class="gp">% </span>git<span class="w"> </span>push<span class="w"> </span>origin<span class="w"> </span>your-working-branch |
| 599 |
</pre></div> |
| 600 |
</div> |
| 601 |
</section> |
| 602 |
<section id="submit-your-pull-request"> |
| 603 |
<h3><span class="section-number">12.2.1.8.3. </span>プルリクエストを送る<a class="headerlink" href="#submit-your-pull-request" title="Link to this heading">#</a></h3> |
| 604 |
<p>これで、アップストリームのGroongaリポジトリにプルリクエストを送る準備ができました。次のステップに従い実際にプルリクエストを送ってみましょう。</p> |
| 605 |
<ol class="arabic simple"> |
| 606 |
<li><p>GitHubで自分のフォークリポジトリにアクセスします</p></li> |
| 607 |
<li><p><code class="docutils literal notranslate"><span class="pre">Compare</span> <span class="pre">&</span> <span class="pre">pull</span> <span class="pre">request</span></code>ボタンをクリックします</p></li> |
| 608 |
<li><p>変更がすべて反映されているかを確認します</p></li> |
| 609 |
<li><p><code class="docutils literal notranslate"><span class="pre">Create</span> <span class="pre">Pull</span> <span class="pre">Request</span></code>ボタンをクリックして、プルリクエストを送ります</p></li> |
| 610 |
</ol> |
| 611 |
</section> |
| 612 |
</section> |
| 613 |
<section id="optional-translate-documentation"> |
| 614 |
<h2><span class="section-number">12.2.1.9. </span>任意: ドキュメントを翻訳する<a class="headerlink" href="#optional-translate-documentation" title="Link to this heading">#</a></h2> |
| 615 |
<p>任意のステップになります。</p> |
| 616 |
<p>Groongaドキュメントの編集とプレビューが完了したら、次のステップは、ドキュメントの翻訳になります。翻訳をすることで、Groongaコミュニティのより広い範囲のユーザーがGroongaを利用しやすくなります。英語以外の言語に翻訳することで、非英語話者でもGroongaのドキュメントを理解しやすくなります。次の手順で、Groongaドキュメントを翻訳しましょう。</p> |
| 617 |
<ol class="arabic simple"> |
| 618 |
<li><p><code class="docutils literal notranslate"><span class="pre">.edit.po</span></code> ファイル内のドキュメントを翻訳する</p></li> |
| 619 |
<li><p>翻訳を <code class="docutils literal notranslate"><span class="pre">.po</span></code> ファイルに反映する</p></li> |
| 620 |
<li><p>HTMLファイルで翻訳を確認する</p></li> |
| 621 |
</ol> |
| 622 |
<section id="translate-the-documentation-in-edit-po-files"> |
| 623 |
<h3><span class="section-number">12.2.1.9.1. </span><code class="docutils literal notranslate"><span class="pre">.edit.po</span></code> ファイル内のドキュメントを翻訳する<a class="headerlink" href="#translate-the-documentation-in-edit-po-files" title="Link to this heading">#</a></h3> |
| 624 |
<p>次のコマンドで、翻訳用である <code class="docutils literal notranslate"><span class="pre">.edit.po</span></code> ファイルを生成します。生成されたファイルは <code class="docutils literal notranslate"><span class="pre">../groonga.doc/doc/locale/${LANGUAGE}/LC_MESSAGES</span></code> 配下にあります。各 <code class="docutils literal notranslate"><span class="pre">.rst</span></code> または <code class="docutils literal notranslate"><span class="pre">.md</span></code> ファイルに対応するファイルが生成されています。対応する <code class="docutils literal notranslate"><span class="pre">.edit.po</span></code> ファイルに翻訳を追加します。</p> |
| 625 |
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="gp">% </span>cmake<span class="w"> </span>--build<span class="w"> </span>../groonga.doc |
| 626 |
</pre></div> |
| 627 |
</div> |
| 628 |
<p>例えば、この <a class="reference internal" href="#"><span class="doc">導入</span></a> ページを編集して、日本語訳を追加したい場合は、<code class="docutils literal notranslate"><span class="pre">../groonga.doc/doc/ja/LC_MESSAGES/contribution/documentation/introduction.edit.po</span></code> ファイルを更新します。</p> |
| 629 |
<div class="admonition caution"> |
| 630 |
<p class="admonition-title">注意</p> |
| 631 |
<p><code class="docutils literal notranslate"><span class="pre">.edit.po</span></code> ファイルに翻訳を追加している最中に、翻訳元の <code class="docutils literal notranslate"><span class="pre">.rst</span></code> または <code class="docutils literal notranslate"><span class="pre">.md</span></code> ファイルを変更しないでください。翻訳した内容を <code class="docutils literal notranslate"><span class="pre">.po</span></code> ファイルに反映せずにを翻訳元を編集してしまうと、翻訳内容が消えてしまいます。翻訳元を編集したい場合は先に翻訳内容を <code class="docutils literal notranslate"><span class="pre">.po</span></code> ファイルに反映してください。反映方法は次のステップで紹介します。</p> |
| 632 |
</div> |
| 633 |
</section> |
| 634 |
<section id="reflect-translations-to-po-files"> |
| 635 |
<h3><span class="section-number">12.2.1.9.2. </span>翻訳を <code class="docutils literal notranslate"><span class="pre">.po</span></code> ファイルに反映する<a class="headerlink" href="#reflect-translations-to-po-files" title="Link to this heading">#</a></h3> |
| 636 |
<p><code class="docutils literal notranslate"><span class="pre">.edit.po</span></code> ファイルに翻訳を追加した後、<code class="docutils literal notranslate"><span class="pre">.po</span></code> ファイルへ翻訳を反映するのが、次のステップになります。<code class="docutils literal notranslate"><span class="pre">.po</span></code> ファイルは、最終的な翻訳ファイルになります。ファイルは、<code class="docutils literal notranslate"><span class="pre">doc/locale/${LANGUAGE}/LC_MESSAGES</span></code> 配下にあります。各 <code class="docutils literal notranslate"><span class="pre">.rst</span></code> または <code class="docutils literal notranslate"><span class="pre">.md</span></code> ファイルに対応しています。翻訳を編集したい場合は、対応する <code class="docutils literal notranslate"><span class="pre">.edit.po</span></code> ファイルを編集してから、変更内容を <code class="docutils literal notranslate"><span class="pre">.po</span></code> ファイルに反映し直す必要があります。</p> |
| 637 |
<p>次のコマンドで、翻訳内容を <code class="docutils literal notranslate"><span class="pre">.edit.po</span></code> ファイルから <code class="docutils literal notranslate"><span class="pre">.po</span></code> ファイルへ反映します。</p> |
| 638 |
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="gp">% </span>cmake<span class="w"> </span>--build<span class="w"> </span>../groonga.doc |
| 639 |
</pre></div> |
| 640 |
</div> |
| 641 |
<p>例えば、この <a class="reference internal" href="#"><span class="doc">導入</span></a> ページの日本語訳を行い、上記のコマンドを実行した場合、翻訳内容は、<code class="docutils literal notranslate"><span class="pre">/doc/locale/ja/LC_MESSAGES/contribution/documentation/introduction.po</span></code> ファイルに反映されます。</p> |
| 642 |
<div class="admonition note"> |
| 643 |
<p class="admonition-title">注釈</p> |
| 644 |
<p>実は、翻訳を反映するコマンドは、翻訳用の <code class="docutils literal notranslate"><span class="pre">.edit.po</span></code> ファイルを生成するコマンドと同じコマンドです。なので、翻訳用のファイル生成と翻訳の反映で違うコマンドを覚える必要はありません。</p> |
| 645 |
</div> |
| 646 |
</section> |
| 647 |
<section id="preview-translations-on-html-files"> |
| 648 |
<h3><span class="section-number">12.2.1.9.3. </span>HTMLファイルで翻訳を確認する<a class="headerlink" href="#preview-translations-on-html-files" title="Link to this heading">#</a></h3> |
| 649 |
<p>翻訳が反映されたHTML形式のドキュメントをWebブラウザで確認できます。翻訳を <code class="docutils literal notranslate"><span class="pre">.po</span></code> ファイルに反映するステップにて、HTMLファイルも生成されています。これらのファイルは <code class="docutils literal notranslate"><span class="pre">../groonga.doc/doc/${LANGUAGE}/html/</span></code> 配下に生成されています。各ファイルは <code class="docutils literal notranslate"><span class="pre">.rst</span></code> または <code class="docutils literal notranslate"><span class="pre">.md</span></code> ファイルに対応しています。生成されたファイルをWebブラウザで開き、翻訳を確認できます。</p> |
| 650 |
<p>例えば、<a class="reference internal" href="#"><span class="doc">導入</span></a> ページに日本語訳を追加した場合、次のコマンドで確認できます</p> |
| 651 |
<div class="highlight-console notranslate"><div class="highlight"><pre><span></span><span class="gp">% </span>open<span class="w"> </span>../groonga.doc/doc/ja/html/contribution/documentation/introduction.html |
| 652 |
</pre></div> |
| 653 |
</div> |
| 654 |
<p>翻訳を確認して正しく反映されていたらパッチを送りましょう。送り方については、<a class="reference internal" href="#send-patch">パッチを送る</a>を参照してください。</p> |
| 655 |
</section> |
| 656 |
</section> |
| 657 |
</section> |
| 658 |
|
| 659 |
|
| 660 |
</article> |
| 661 |
|
| 662 |
|
| 663 |
|
| 664 |
|
| 665 |
|
| 666 |
<footer class="prev-next-footer d-print-none"> |
| 667 |
|
| 668 |
<div class="prev-next-area"> |
| 669 |
<a class="left-prev" |
| 670 |
href="../documentation.html" |
| 671 |
title="前のページ"> |
| 672 |
<i class="fa-solid fa-angle-left"></i> |
| 673 |
<div class="prev-next-info"> |
| 674 |
<p class="prev-next-subtitle">前へ</p> |
| 675 |
<p class="prev-next-title"><span class="section-number">12.2. </span>ドキュメント関連のコントリビュート方法</p> |
| 676 |
</div> |
| 677 |
</a> |
| 678 |
<a class="right-next" |
| 679 |
href="i18n.html" |
| 680 |
title="次ページ"> |
| 681 |
<div class="prev-next-info"> |
| 682 |
<p class="prev-next-subtitle">次へ</p> |
| 683 |
<p class="prev-next-title"><span class="section-number">12.2.2. </span>国際化</p> |
| 684 |
</div> |
| 685 |
<i class="fa-solid fa-angle-right"></i> |
| 686 |
</a> |
| 687 |
</div> |
| 688 |
</footer> |
| 689 |
|
| 690 |
</div> |
| 691 |
|
| 692 |
|
| 693 |
|
| 694 |
<dialog id="pst-secondary-sidebar-modal"></dialog> |
| 695 |
<div id="pst-secondary-sidebar" class="bd-sidebar-secondary bd-toc"><div class="sidebar-secondary-items sidebar-secondary__inner"> |
| 696 |
|
| 697 |
|
| 698 |
<div class="sidebar-secondary-item"> |
| 699 |
<div |
| 700 |
id="pst-page-navigation-heading-2" |
| 701 |
class="page-toc tocsection onthispage"> |
| 702 |
<i class="fa-solid fa-list"></i> このページでは |
| 703 |
</div> |
| 704 |
<nav id="pst-page-toc-nav" class="page-toc" aria-labelledby="pst-page-navigation-heading-2"> |
| 705 |
<ul class="pst-show_toc_level nav section-nav flex-column"> |
| 706 |
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#how-to-fork-and-clone-groonga-repository">12.2.1.1. Groongaリポジトリをフォークしクローンする方法</a></li> |
| 707 |
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#install-dependent-software">12.2.1.2. 必要なソフトウェアのインストール</a></li> |
| 708 |
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#run-cmake-with-preset-doc">12.2.1.3. <code class="docutils literal notranslate"><span class="pre">cmake</span></code> を <code class="docutils literal notranslate"><span class="pre">--preset=doc</span></code> 付きで実行</a></li> |
| 709 |
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#generate-html">12.2.1.4. HTMLファイルを生成</a></li> |
| 710 |
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#how-to-edit-documentation">12.2.1.5. ドキュメントを編集する方法</a></li> |
| 711 |
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#how-to-add-a-new-documentation">12.2.1.6. 新しいドキュメントを追加する方法</a></li> |
| 712 |
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#preview-changes-on-html-files">12.2.1.7. HTMLファイルで変更を確認する</a><ul class="nav section-nav flex-column"> |
| 713 |
<li class="toc-h3 nav-item toc-entry"><a class="reference internal nav-link" href="#generate-the-html-files-with-your-changes">12.2.1.7.1. 変更を反映したHTMLファイルを生成する</a></li> |
| 714 |
<li class="toc-h3 nav-item toc-entry"><a class="reference internal nav-link" href="#preview-the-generated-html-files-in-your-web-browser">12.2.1.7.2. Webブラウザで生成されたHTMLファイルを確認する</a></li> |
| 715 |
</ul> |
| 716 |
</li> |
| 717 |
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#send-patch">12.2.1.8. パッチを送る</a><ul class="nav section-nav flex-column"> |
| 718 |
<li class="toc-h3 nav-item toc-entry"><a class="reference internal nav-link" href="#enable-preview-on-your-fork-optional">12.2.1.8.1. フォーク先リポジトリでプレビューを有効にする(任意)</a></li> |
| 719 |
<li class="toc-h3 nav-item toc-entry"><a class="reference internal nav-link" href="#prepare-your-pull-request">12.2.1.8.2. プルリクエストの準備をする</a></li> |
| 720 |
<li class="toc-h3 nav-item toc-entry"><a class="reference internal nav-link" href="#submit-your-pull-request">12.2.1.8.3. プルリクエストを送る</a></li> |
| 721 |
</ul> |
| 722 |
</li> |
| 723 |
<li class="toc-h2 nav-item toc-entry"><a class="reference internal nav-link" href="#optional-translate-documentation">12.2.1.9. 任意: ドキュメントを翻訳する</a><ul class="nav section-nav flex-column"> |
| 724 |
<li class="toc-h3 nav-item toc-entry"><a class="reference internal nav-link" href="#translate-the-documentation-in-edit-po-files">12.2.1.9.1. <code class="docutils literal notranslate"><span class="pre">.edit.po</span></code> ファイル内のドキュメントを翻訳する</a></li> |
| 725 |
<li class="toc-h3 nav-item toc-entry"><a class="reference internal nav-link" href="#reflect-translations-to-po-files">12.2.1.9.2. 翻訳を <code class="docutils literal notranslate"><span class="pre">.po</span></code> ファイルに反映する</a></li> |
| 726 |
<li class="toc-h3 nav-item toc-entry"><a class="reference internal nav-link" href="#preview-translations-on-html-files">12.2.1.9.3. HTMLファイルで翻訳を確認する</a></li> |
| 727 |
</ul> |
| 728 |
</li> |
| 729 |
</ul> |
| 730 |
</nav></div> |
| 731 |
|
| 732 |
</div></div> |
| 733 |
|
| 734 |
|
| 735 |
</div> |
| 736 |
<footer class="bd-footer-content"> |
| 737 |
|
| 738 |
</footer> |
| 739 |
|
| 740 |
</main> |
| 741 |
</div> |
| 742 |
</div> |
| 743 |
|
| 744 |
|
| 745 |
<script defer src="../../_static/scripts/bootstrap.js?digest=90905a2f556bf617f1a9"></script> |
| 746 |
<script defer src="../../_static/scripts/pydata-sphinx-theme.js?digest=90905a2f556bf617f1a9"></script> |
| 747 |
|
| 748 |
<footer class="bd-footer"> |
| 749 |
<div class="bd-footer__inner bd-page-width"> |
| 750 |
|
| 751 |
<div class="footer-items__start"> |
| 752 |
|
| 753 |
<div class="footer-item"> |
| 754 |
|
| 755 |
<p class="copyright"> |
| 756 |
|
| 757 |
© Copyright 2009-2026 Groonga Project. |
| 758 |
<br/> |
| 759 |
|
| 760 |
</p> |
| 761 |
</div> |
| 762 |
|
| 763 |
</div> |
| 764 |
|
| 765 |
|
| 766 |
|
| 767 |
<div class="footer-items__end"> |
| 768 |
|
| 769 |
<div class="footer-item"> |
| 770 |
<p class="theme-version"> |
| 771 |
|
| 772 |
<a href="https://pydata-sphinx-theme.readthedocs.io/en/stable/index.html">PyData Sphinx Theme</a> 0.20.0 で構築されています。 |
| 773 |
</p></div> |
| 774 |
|
| 775 |
</div> |
| 776 |
|
| 777 |
</div> |
| 778 |
|
| 779 |
</footer> |
| 780 |
</body> |
| 781 |
</html> |