{"id":1951,"date":"2026-04-05T15:42:32","date_gmt":"2026-04-05T06:42:32","guid":{"rendered":"https:\/\/syuji-engineer.com\/?p=1951"},"modified":"2026-04-05T15:42:45","modified_gmt":"2026-04-05T06:42:45","slug":"wordpress%e3%81%ae%e8%a8%98%e4%ba%8b%e3%81%8c%e6%b6%88%e3%81%88%e3%82%8b%e5%89%8d%e3%81%ab%e3%82%84%e3%81%a3%e3%81%9f1%e3%81%a4%e3%81%ae%e3%81%93%e3%81%a8","status":"publish","type":"post","link":"https:\/\/syuji-engineer.com\/?p=1951","title":{"rendered":"WordPress\u306e\u8a18\u4e8b\u304c\u6d88\u3048\u308b\u524d\u306b\u3084\u3063\u305f1\u3064\u306e\u3053\u3068"},"content":{"rendered":"\n<p>\u203b\u3053\u306e\u8a18\u4e8b\u306b\u306f\u30a2\u30d5\u30a3\u30ea\u30a8\u30a4\u30c8\u30ea\u30f3\u30af\u3092\u542b\u307f\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">WordPress\u8a18\u4e8b\u306fMarkdown\uff0bGitHub\u3067\u5b88\u308c\u308b<\/h3>\n\n\n\n<p>\u7d50\u8ad6\u304b\u3089\u8a00\u3044\u307e\u3059\u3002<\/p>\n\n\n\n<p>WordPress\u306e\u8a18\u4e8b\u306f\u300eXML\u30a8\u30af\u30b9\u30dd\u30fc\u30c8 \u2192 Markdown\u5909\u63db \u2192 GitHub\u7ba1\u7406\u300f\u306e3\u30b9\u30c6\u30c3\u30d7\u3067\u5b88\u308c\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u30b5\u30fc\u30d0\u30fc\u304c\u98db\u3093\u3067\u3082\u3001\u30b5\u30fc\u30d3\u30b9\u304c\u7d42\u4e86\u3057\u3066\u3082\u3001\u624b\u5143\u3068GitHub\u306b\u8a18\u4e8b\u304c\u6b8b\u308b\u72b6\u614b\u3092\u4f5c\u308c\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u4e00\u5ea6\u4ed5\u7d44\u307f\u3092\u4f5c\u3063\u3066\u3057\u307e\u3048\u3070\u3001\u3042\u3068\u306f\u67081\u56de\u306e\u4f5c\u696d\u3060\u3051\u3067\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\u300c\u8a18\u4e8b\u304c\u5168\u90e8\u6d88\u3048\u305f\u3089\u300d\u3068\u601d\u3063\u305f\u65e5<\/h3>\n\n\n\n<p>WordPress\u3067\u30d6\u30ed\u30b0\u3092\u7d9a\u3051\u3066\u3044\u308b\u3068\u3001\u3075\u3068\u6c17\u3065\u304f\u77ac\u9593\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u300c\u3053\u306e\u8a18\u4e8b\u3001\u5168\u90e8\u30b5\u30fc\u30d0\u30fc\u306e\u4e2d\u306b\u3057\u304b\u306a\u3044\u306a\u300d\u3068\u3002<\/p>\n\n\n\n<p>\u81ea\u5206\u306e\u5834\u5408\u3001\u8a18\u4e8b\u304c\u305d\u3053\u305d\u3053\u5897\u3048\u3066\u304d\u305f\u30bf\u30a4\u30df\u30f3\u30b0\u3067\u3057\u305f\u3002\u3075\u3068\u30b5\u30fc\u30d0\u30fc\u969c\u5bb3\u306e\u30cb\u30e5\u30fc\u30b9\u3092\u898b\u3066\u3001\u300c\u3082\u3057\u3053\u306e\u30b5\u30fc\u30d0\u30fc\u304c\u6b62\u307e\u3063\u305f\u3089\u3001\u4f55\u3082\u6b8b\u3089\u306a\u3044\u306e\u3067\u306f\u300d\u3068\u601d\u3063\u305f\u3093\u3067\u3059\u3002<\/p>\n\n\n\n<p>WordPress\u306e\u8a18\u4e8b\u30c7\u30fc\u30bf\u306f\u3001\u30b5\u30fc\u30d0\u30fc\u4e0a\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306b\u4fdd\u5b58\u3055\u308c\u3066\u3044\u307e\u3059\u3002\u3064\u307e\u308a\u3001\u30b5\u30fc\u30d0\u30fc\u304c\u58ca\u308c\u305f\u308a\u3001\u30b5\u30fc\u30d3\u30b9\u304c\u7d42\u4e86\u3057\u305f\u308a\u3059\u308c\u3070\u3001\u9577\u5e74\u66f8\u3044\u3066\u304d\u305f\u8a18\u4e8b\u304c\u4e00\u77ac\u3067\u6d88\u3048\u308b\u53ef\u80fd\u6027\u304c\u3042\u308b\u3002<\/p>\n\n\n\n<p>\u3053\u308c\u306f\u63a8\u6e2c\u3067\u3082\u8105\u3057\u3067\u3082\u306a\u304f\u3001\u4ed5\u7d44\u307f\u3068\u3057\u3066\u305d\u3046\u306a\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u3067\u3001\u5b9f\u969b\u306b\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u306e\u4ed5\u7d44\u307f\u3092\u8abf\u3079\u3066\u307f\u308b\u3068\u3001\u610f\u5916\u3068\u30b7\u30f3\u30d7\u30eb\u306a\u65b9\u6cd5\u3067\u89e3\u6c7a\u3067\u304d\u307e\u3057\u305f\u3002\u305d\u308c\u304c\u4eca\u56de\u306e\u8a71\u3067\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">WordPress\u3060\u3051\u306b\u8a18\u4e8b\u3092\u7f6e\u304f\u30ea\u30b9\u30af<\/h3>\n\n\n\n<p>WordPress\u3067\u8a18\u4e8b\u3092\u7ba1\u7406\u3059\u308b\u3068\u304d\u3001\u591a\u304f\u306e\u4eba\u306f\u30b5\u30fc\u30d0\u30fc\u4e0a\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u3060\u3051\u306b\u8a18\u4e8b\u3092\u9810\u3051\u3066\u3044\u308b\u72b6\u614b\u306b\u306a\u3063\u3066\u3044\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u3053\u306e\u69cb\u9020\u306b\u306f\u3001\u3044\u304f\u3064\u304b\u30ea\u30b9\u30af\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u30b5\u30fc\u30d0\u30fc\u969c\u5bb3\u3067\u8a18\u4e8b\u30c7\u30fc\u30bf\u304c\u6d88\u3048\u308b\u53ef\u80fd\u6027\u304c\u3042\u308b<\/li>\n\n\n\n<li>\u30ec\u30f3\u30bf\u30eb\u30b5\u30fc\u30d0\u30fc\u4f1a\u793e\u304c\u30b5\u30fc\u30d3\u30b9\u3092\u7d42\u4e86\u3059\u308b\u53ef\u80fd\u6027\u304c\u3042\u308b<\/li>\n\n\n\n<li>\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u7528\u30d7\u30e9\u30b0\u30a4\u30f3\u304c\u6b63\u5e38\u306b\u52d5\u3044\u3066\u3044\u308b\u304b\u3069\u3046\u304b\u3001\u5b9f\u306f\u78ba\u8a8d\u3057\u3066\u3044\u306a\u3044\u4eba\u304c\u591a\u3044<\/li>\n\n\n\n<li>REST API\u3067\u81ea\u52d5\u53d6\u5f97\u3057\u3088\u3046\u3068\u3057\u3066\u3082\u3001\u30b5\u30fc\u30d0\u30fc\u3084\u30d7\u30e9\u30b0\u30a4\u30f3\u306e\u8a2d\u5b9a\u3067\u4f7f\u3048\u306a\u3044\u30b1\u30fc\u30b9\u304c\u3042\u308b<\/li>\n<\/ul>\n\n\n\n<p>\u8981\u306f\u3001\u300e\u30b5\u30fc\u30d0\u30fc\u306b\u5168\u90e8\u4efb\u305b\u3066\u3044\u308b\u300f\u72b6\u614b\u306f\u3001\u601d\u3063\u3066\u3044\u308b\u4ee5\u4e0a\u306b\u8106\u3044\u3068\u3044\u3046\u3053\u3068\u3067\u3059\u3002<\/p>\n\n\n\n<p>\u300c\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u3057\u3066\u308b\u3064\u3082\u308a\u300d\u3068\u300c\u5fa9\u5143\u3067\u304d\u308b\u72b6\u614b\u300d\u306f\u5225\u7269\u3067\u3059\u3002<\/p>\n\n\n\n<!-- Google -->\n<script async src=\"https:\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js?client=ca-pub-8421777867084732\"\n     crossorigin=\"anonymous\"><\/script>\n<!-- \u30b9\u30af\u30a8\u30a2 -->\n<ins class=\"adsbygoogle\"\n     style=\"display:block\"\n     data-ad-client=\"ca-pub-8421777867084732\"\n     data-ad-slot=\"8629238674\"\n     data-ad-format=\"auto\"\n     data-full-width-responsive=\"true\"><\/ins>\n<script>\n     (adsbygoogle = window.adsbygoogle || []).push({});\n<\/script>\n\n\n\n<h3 class=\"wp-block-heading\">\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u3092\u5148\u9001\u308a\u306b\u3059\u308b\u4eba\u306e\u5171\u901a\u70b9<\/h3>\n\n\n\n<p>\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u3092\u3084\u3089\u306a\u3044\u4eba\u306b\u306f\u3001\u3060\u3044\u305f\u3044\u5171\u901a\u3059\u308b\u30d1\u30bf\u30fc\u30f3\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n\n\n\n<p>1\u3064\u76ee\u3002\u300e\u30d7\u30e9\u30b0\u30a4\u30f3\u3067\u81ea\u52d5\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u3057\u3066\u308b\u304b\u3089\u5927\u4e08\u592b\u300f\u3068\u601d\u3063\u3066\u3044\u308b\u3002\u3067\u3082\u3001\u305d\u306e\u30d7\u30e9\u30b0\u30a4\u30f3\u306e\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u5148\u304c\u30b5\u30fc\u30d0\u30fc\u5185\u3060\u3063\u305f\u308a\u3059\u308b\u3068\u3001\u30b5\u30fc\u30d0\u30fc\u3054\u3068\u6d88\u3048\u307e\u3059\u3002<\/p>\n\n\n\n<p>2\u3064\u76ee\u3002\u300e\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u306e\u5b58\u5728\u306f\u77e5\u3063\u3066\u308b\u3051\u3069\u3001\u4e00\u5ea6\u3082\u5fa9\u5143\u30c6\u30b9\u30c8\u3092\u3057\u305f\u3053\u3068\u304c\u306a\u3044\u300f\u3002\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u306f\u53d6\u308c\u3066\u3044\u3066\u3082\u3001\u3044\u3056\u3068\u3044\u3046\u3068\u304d\u5fa9\u5143\u3067\u304d\u308b\u304b\u3069\u3046\u304b\u306f\u8a66\u3057\u3066\u307f\u306a\u3044\u3068\u308f\u304b\u3089\u306a\u3044\u3067\u3059\u3002<\/p>\n\n\n\n<p>3\u3064\u76ee\u3002\u300e\u307e\u3060\u8a18\u4e8b\u304c\u5c11\u306a\u3044\u3057\u300f\u3068\u5f8c\u56de\u3057\u306b\u3057\u3066\u3044\u308b\u3002\u3067\u3082\u3001\u8a18\u4e8b\u304c\u5897\u3048\u3066\u304b\u3089\u3084\u308d\u3046\u3068\u3059\u308b\u3068\u3001\u9762\u5012\u306b\u306a\u3063\u3066\u3055\u3089\u306b\u5f8c\u56de\u3057\u306b\u306a\u308b\u3002\u7d50\u5c40\u3084\u3089\u306a\u3044\u307e\u307e\u6642\u9593\u304c\u7d4c\u3064\u30d1\u30bf\u30fc\u30f3\u3067\u3059\u3002<\/p>\n\n\n\n<p>4\u3064\u76ee\u3002\u300e\u30b5\u30fc\u30d0\u30fc\u4f1a\u793e\u304c\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u3057\u3066\u304f\u308c\u3066\u3044\u308b\u300f\u3068\u4fe1\u3058\u3066\u3044\u308b\u3002\u4f1a\u793e\u306b\u3088\u3063\u3066\u306f\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u3057\u3066\u304f\u308c\u307e\u3059\u304c\u3001\u4fdd\u6301\u671f\u9593\u3084\u5fa9\u5143\u306e\u6761\u4ef6\u306f\u4f1a\u793e\u3054\u3068\u306b\u9055\u3044\u307e\u3059\u3002\u5168\u90e8\u623b\u308b\u4fdd\u8a3c\u306f\u306a\u3044\u3067\u3059\u3002<\/p>\n\n\n\n<!-- \u554f\u3044\u30ab\u30fc\u30c9\uff1aHTML_BLOCK_ASK -->\n<div style=\"border:1px solid #e5e7eb;border-radius:12px;padding:16px;margin:24px 0;background:#fafafa;\">\n  <div style=\"font-weight:700;margin-bottom:6px;\">\u8003\u3048\u76f4\u3059<\/div>\n  <div style=\"padding-left:12px;border-left:3px solid #111;line-height:1.7;\">\n    \u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u3001\u300c\u3084\u3063\u3066\u308b\u3064\u3082\u308a\u300d\u3067\u6b62\u307e\u3063\u3066\u3044\u306a\u3044\u304b\u8003\u3048\u76f4\u3057\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002<br>\n     \u30fb\u3042\u306a\u305f\u306e\u8a18\u4e8b\u3001\u4eca\u30b5\u30fc\u30d0\u30fc\u304c\u6d88\u3048\u305f\u3089\u4f55\u672c\u624b\u5143\u306b\u6b8b\u308a\u307e\u3059\u304b\uff1f\n  <\/div>\n<\/div>\n\n\n\n<h3 class=\"wp-block-heading\">\u3084\u308b\u3053\u3068\uff1a3\u30b9\u30c6\u30c3\u30d7\u3067\u8a18\u4e8b\u3092GitHub\u306b\u9003\u304c\u3059<\/h3>\n\n\n\n<p>\u4eca\u65e5\u3084\u308b\u3053\u3068\u306f1\u3064\u3060\u3051\u3002\u307e\u305a\u300eSTEP 1\u306eXML\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u300f\u3092\u3084\u3063\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n\n\n\n<!-- \u4eca\u65e5\u3084\u308b\u3053\u3068\u30ab\u30fc\u30c9\uff1aHTML_BLOCK_ONE -->\n<div style=\"border:1px solid #e5e7eb;border-radius:12px;padding:16px;margin:24px 0;background:#fafafa;\">\n  <div style=\"font-weight:700;margin-bottom:6px;\">\u307e\u305a\u306f\uff11\u3064\u3084\u3063\u3066\u307f\u308b<\/div>\n  <div style=\"line-height:1.7;\">\n    \u30fbWordPress\u7ba1\u7406\u753b\u9762\u306e\u300c\u30c4\u30fc\u30eb \u2192 \u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u300d\u304b\u3089XML\u30d5\u30a1\u30a4\u30eb\u30921\u56de\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3059\u308b\n  <\/div>\n<\/div>\n\n\n\n<p>\u5168\u4f53\u306e\u6d41\u308c\u306f3\u30b9\u30c6\u30c3\u30d7\u3067\u3059\u3002<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">STEP 1\uff1aWordPress\u304b\u3089XML\u3092\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u3059\u308b<\/h4>\n\n\n\n<p>WordPress\u306b\u306f\u8a18\u4e8b\u3092\u4e38\u3054\u3068\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u3059\u308b\u6a5f\u80fd\u304c\u6a19\u6e96\u3067\u4ed8\u3044\u3066\u3044\u307e\u3059\u3002<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>WordPress\u7ba1\u7406\u753b\u9762\u306b\u30ed\u30b0\u30a4\u30f3<\/li>\n\n\n\n<li>\u300c\u30c4\u30fc\u30eb \u2192 \u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u300d\u306b\u30a2\u30af\u30bb\u30b9<\/li>\n\n\n\n<li>\u300c\u3059\u3079\u3066\u306e\u30b3\u30f3\u30c6\u30f3\u30c4\u300d\u3092\u9078\u629e<\/li>\n\n\n\n<li>\u300c\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u30d5\u30a1\u30a4\u30eb\u3092\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u300d\u3092\u30af\u30ea\u30c3\u30af<\/li>\n<\/ol>\n\n\n\n<p>\u3053\u308c\u3067 <code>WordPress.2026-04-05.xml<\/code> \u306e\u3088\u3046\u306a\u540d\u524d\u306e\u30d5\u30a1\u30a4\u30eb\u304c\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u3055\u308c\u307e\u3059\u3002\u3053\u306e\u30d5\u30a1\u30a4\u30eb\u3092 <code>~\/ai-blog\/<\/code> \u30d5\u30a9\u30eb\u30c0\u306b\u7f6e\u3044\u3066\u304a\u304d\u307e\u3059\u3002<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">STEP 2\uff1aPython\u3067XML\u3092Markdown\u306b\u5909\u63db\u3059\u308b<\/h4>\n\n\n\n<p>\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u3057\u305fXML\u30d5\u30a1\u30a4\u30eb\u3092\u3001Python\u30b9\u30af\u30ea\u30d7\u30c8\u3067\u4e00\u62ec\u5909\u63db\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u307e\u305a\u30e9\u30a4\u30d6\u30e9\u30ea\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"wp-block-verse\">pip3 install html2text<\/pre>\n\n\n\n<p>\u6b21\u306b\u3001\u4ee5\u4e0b\u306e\u30b9\u30af\u30ea\u30d7\u30c8\u3092 <code>~\/ai-blog\/scripts\/xml_to_markdown.py<\/code> \u3068\u3057\u3066\u4fdd\u5b58\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"wp-block-verse\">#!\/usr\/bin\/env python3<br>import os<br>import re<br>import xml.etree.ElementTree as ET<br>from datetime import datetime<br>import html2text<br><br>BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))<br>XML_FILE = os.path.join(BASE_DIR, \"WordPress.2026-04-05.xml\")<br><br>NAMESPACES = {<br>    \"content\": \"http:\/\/purl.org\/rss\/1.0\/modules\/content\/\",<br>    \"wp\":      \"http:\/\/wordpress.org\/export\/1.2\/\",<br>    \"dc\":      \"http:\/\/purl.org\/dc\/elements\/1.1\/\",<br>}<br><br>def html_to_markdown(html):<br>    converter = html2text.HTML2Text()<br>    converter.ignore_links = False<br>    converter.ignore_images = False<br>    converter.body_width = 0<br>    return converter.handle(html).strip()<br><br>def parse_posts(xml_file):<br>    tree = ET.parse(xml_file)<br>    root = tree.getroot()<br>    posts = []<br>    for item in root.iter(\"item\"):<br>        post_type = item.find(\"wp:post_type\", NAMESPACES)<br>        if post_type is None or post_type.text != \"post\":<br>            continue<br>        posts.append({<br>            \"title\":   item.findtext(\"title\") or \"\",<br>            \"link\":    item.findtext(\"link\") or \"\",<br>            \"date\":    item.findtext(\"wp:post_date\", namespaces=NAMESPACES) or \"\",<br>            \"status\":  item.findtext(\"wp:status\", namespaces=NAMESPACES) or \"\",<br>            \"content\": item.findtext(\"content:encoded\", namespaces=NAMESPACES) or \"\",<br>        })<br>    return posts<br><br>def save_post(post, index):<br>    try:<br>        dt = datetime.strptime(post[\"date\"], \"%Y-%m-%d %H:%M:%S\")<br>    except Exception:<br>        dt = datetime.now()<br><br>    title_for_filename = re.sub(r'[\/\\\\:*?\"&lt;&gt;|]', \"\", post[\"title\"]).strip() or f\"post-{index}\"<br>    filename = f\"{dt.strftime('%Y-%m-%d')}-{title_for_filename}.md\"<br>    save_dir = os.path.join(BASE_DIR, \"posts\", dt.strftime(\"%Y\"), dt.strftime(\"%m\"))<br>    os.makedirs(save_dir, exist_ok=True)<br><br>    body = html_to_markdown(post[\"content\"]) if post[\"content\"] else \"\"<br>    md = f\"\"\"---<br>title: \"{post['title'].replace('\"', \"'\")}\"<br>date: {dt.strftime('%Y-%m-%d')}<br>status: {post['status']}<br>original_url: {post['link']}<br>---<br><br># {post['title']}<br><br>{body}<br>\"\"\"<br>    with open(os.path.join(save_dir, filename), \"w\", encoding=\"utf-8\") as f:<br>        f.write(md)<br><br>def main():<br>    posts = parse_posts(XML_FILE)<br>    print(f\"{len(posts)}\u4ef6\u306e\u8a18\u4e8b\u3092\u5909\u63db\u3057\u307e\u3059...\")<br>    for i, post in enumerate(posts, 1):<br>        save_post(post, i)<br>        print(f\"  [{i}\/{len(posts)}] {post['title'][:45]}\")<br>    print(\"\u5b8c\u4e86\uff01\")<br><br>if __name__ == \"__main__\":<br>    main()<\/pre>\n\n\n\n<p>\u5b9f\u884c\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"wp-block-verse\">python3 ~\/ai-blog\/scripts\/xml_to_markdown.py<\/pre>\n\n\n\n<p>\u5b9f\u884c\u3059\u308b\u3068 <code>posts\/\u5e74\/\u6708\/<\/code> \u30d5\u30a9\u30eb\u30c0\u306b\u8a18\u4e8b\u304cMarkdown\u30d5\u30a1\u30a4\u30eb\u3068\u3057\u3066\u4fdd\u5b58\u3055\u308c\u307e\u3059\u3002<\/p>\n\n\n\n<pre class=\"wp-block-verse\">posts\/<br>\u2514\u2500\u2500 2024\/<br>    \u251c\u2500\u2500 08\/<br>    \u2502   \u251c\u2500\u2500 2024-08-06-\u30d6\u30ed\u30b0\u3092\u7acb\u3061\u4e0a\u3052\u305f\u7406\u7531.md<br>    \u2502   \u2514\u2500\u2500 2024-08-08-WordPress\u306e\u81ea\u4f5c\u30d7\u30e9\u30b0\u30a4\u30f3.md<br>    \u2514\u2500\u2500 09\/<br>        \u2514\u2500\u2500 ...<\/pre>\n\n\n\n<p>\u30d5\u30a1\u30a4\u30eb\u540d\u304c\u305d\u306e\u307e\u307e\u8a18\u4e8b\u30bf\u30a4\u30c8\u30eb\u306b\u306a\u308b\u306e\u3067\u3001\u4e00\u76ee\u3067\u5185\u5bb9\u304c\u308f\u304b\u308a\u307e\u3059\u3002<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">STEP 3\uff1aGitHub\u306b\u30a2\u30c3\u30d7\u30ed\u30fc\u30c9\u3057\u3066\u7ba1\u7406\u3059\u308b<\/h4>\n\n\n\n<p>GitHub\u306b\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u4f5c\u3063\u3066\u3001\u5909\u63db\u3057\u305f\u8a18\u4e8b\u3092push\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>GitHub\u3067\u65b0\u898f\u30ea\u30dd\u30b8\u30c8\u30ea\u3092\u4f5c\u6210\uff08Private\u63a8\u5968\uff09<\/li>\n\n\n\n<li>\u4ee5\u4e0b\u306e\u30b3\u30de\u30f3\u30c9\u3067\u521d\u671f\u5316\uff06push<\/li>\n<\/ol>\n\n\n\n<pre class=\"wp-block-verse\">cd ~\/ai-blog<br>git init<br>git add .<br>git commit -m \"\u521d\u56de\u30b3\u30df\u30c3\u30c8: WordPress\u8a18\u4e8b\u3092Markdown\u5316\"<br>git remote add origin https:\/\/github.com\/\u30e6\u30fc\u30b6\u30fc\u540d\/my-blog.git<br>git branch -M main<br>git push -u origin main<\/pre>\n\n\n\n<p>\u3053\u308c\u3067\u8a18\u4e8b\u304cGitHub\u306b\u4fdd\u5b58\u3055\u308c\u307e\u3059\u3002\u5e74\u6708\u30d5\u30a9\u30eb\u30c0\u3054\u3068\u306b\u6574\u7406\u3055\u308c\u305f\u72b6\u614b\u3067\u898b\u3089\u308c\u307e\u3059\u3002<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">\u67081\u56de\u306e\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u904b\u7528<\/h4>\n\n\n\n<p>\u4ed5\u7d44\u307f\u304c\u3067\u304d\u305f\u3089\u3001\u3042\u3068\u306f\u67081\u56de\u3053\u306e\u624b\u9806\u3092\u7e70\u308a\u8fd4\u3059\u3060\u3051\u3067\u3059\u3002<\/p>\n\n\n\n<pre class=\"wp-block-verse\"># 1. WordPress\u304b\u3089XML\u3092\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u3057\u3066 ai-blog\/ \u306b\u7f6e\u304f<br># 2. \u5909\u63db\u30b9\u30af\u30ea\u30d7\u30c8\u3092\u5b9f\u884c<br>python3 ~\/ai-blog\/scripts\/xml_to_markdown.py<br><br># 3. GitHub\u306bpush<br>cd ~\/ai-blog<br>git add .<br>git commit -m \"\u6708\u6b21\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\"<br>git push<\/pre>\n\n\n\n<p>\u6163\u308c\u308c\u30705\u5206\u3067\u7d42\u308f\u308a\u307e\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\u88dc\u8db3\uff1aREST API\u304c\u4f7f\u3048\u306a\u3044\u5834\u5408<\/h3>\n\n\n\n<p>WordPress\u306eREST API\u3092\u4f7f\u3063\u3066\u81ea\u52d5\u53d6\u5f97\u3057\u3088\u3046\u3068\u3059\u308b\u3068\u3001\u30b5\u30fc\u30d0\u30fc\u3084\u30d7\u30e9\u30b0\u30a4\u30f3\u306e\u8a2d\u5b9a\u306b\u3088\u3063\u3066\u52d5\u304b\u306a\u3044\u3053\u3068\u304c\u3042\u308a\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u4eca\u56de\u306e\u3088\u3046\u306bXML\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u3092\u4f7f\u3046\u65b9\u6cd5\u306a\u3089\u3001\u30b5\u30fc\u30d0\u30fc\u8a2d\u5b9a\u3084\u30d7\u30e9\u30b0\u30a4\u30f3\u306e\u5f71\u97ff\u3092\u53d7\u3051\u305a\u306b\u78ba\u5b9f\u306b\u8a18\u4e8b\u3092\u53d6\u308a\u51fa\u305b\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u5ff5\u306e\u305f\u3081\u88dc\u8db3\u3057\u3066\u304a\u304f\u3068\u3001REST API\u304c\u4f7f\u3048\u308b\u74b0\u5883\u306a\u3089\u81ea\u52d5\u5316\u306e\u9078\u629e\u80a2\u3082\u5e83\u304c\u308a\u307e\u3059\u304c\u3001\u300e\u307e\u305a\u78ba\u5b9f\u306b\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u3092\u53d6\u308b\u300f\u3053\u3068\u304c\u5148\u3067\u3059\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\u8a18\u4e8b\u3092\u5b88\u3063\u305f\u3089\u6b21\u306f\u5897\u3084\u3059\u756a<\/h3>\n\n\n\n<p>\u30d0\u30c3\u30af\u30a2\u30c3\u30d7\u306e\u4ed5\u7d44\u307f\u304c\u6574\u3046\u3068\u3001\u30d6\u30ed\u30b0\u904b\u55b6\u306e\u5b89\u5fc3\u611f\u304c\u5909\u308f\u308a\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u300c\u6d88\u3048\u308b\u304b\u3082\u300d\u3068\u3044\u3046\u4e0d\u5b89\u304c\u306a\u304f\u306a\u308b\u3060\u3051\u3067\u3001\u8a18\u4e8b\u3092\u66f8\u304f\u3053\u3068\u306b\u96c6\u4e2d\u3057\u3084\u3059\u304f\u306a\u308b\u3002<\/p>\n\n\n\n<p>\u4ed5\u7d44\u307f\u30921\u56de\u4f5c\u3063\u305f\u3089\u3001\u6b21\u306f\u305d\u306e\u8a18\u4e8b\u3092\u8aad\u8005\u306b\u5c4a\u3051\u308b\u5c0e\u7dda\u306e\u307b\u3046\u306b\u76ee\u3092\u5411\u3051\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\u67081\u56de\u306e\u7fd2\u6163\u3067\u8a18\u4e8b\u306f\u5b88\u308c\u308b<\/h3>\n\n\n\n<p>WordPress\u306e\u8a18\u4e8b\u306f\u3001\u30b5\u30fc\u30d0\u30fc\u4e0a\u306e\u30c7\u30fc\u30bf\u30d9\u30fc\u30b9\u306b\u3060\u3051\u9810\u3051\u3066\u3044\u308b\u72b6\u614b\u3060\u3068\u8106\u3044\u3067\u3059\u3002<\/p>\n\n\n\n<p>\u3067\u3082\u3001XML\u30a8\u30af\u30b9\u30dd\u30fc\u30c8 \u2192 Markdown\u5909\u63db \u2192 GitHub\u7ba1\u7406\u306e3\u30b9\u30c6\u30c3\u30d7\u3092\u67081\u56de\u3084\u308b\u3060\u3051\u3067\u3001\u8a18\u4e8b\u306f\u30ed\u30fc\u30ab\u30eb\u3068GitHub\u306e\u4e21\u65b9\u306b\u6b8b\u308a\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u4ed5\u7d44\u307f\u306f\u4e00\u5ea6\u4f5c\u308c\u3070\u7d42\u308f\u308a\u3002\u3042\u3068\u306f\u67081\u56de\u306e\u7fd2\u6163\u306b\u3059\u308b\u3060\u3051\u3067\u3059\u3002<\/p>\n\n\n\n<p>\u307e\u305a\u306f\u4eca\u65e5\u3001XML\u30a8\u30af\u30b9\u30dd\u30fc\u30c8\u30921\u56de\u3084\u3063\u3066\u307f\u3066\u304f\u3060\u3055\u3044\u3002<\/p>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u203b\u3053\u306e\u8a18\u4e8b\u306b\u306f\u30a2\u30d5\u30a3\u30ea\u30a8\u30a4\u30c8\u30ea\u30f3\u30af\u3092\u542b\u307f\u307e\u3059\u3002 WordPress\u8a18\u4e8b\u306fMarkdown\uff0bGitHub\u3067\u5b88\u308c\u308b \u7d50\u8ad6\u304b\u3089\u8a00\u3044\u307e\u3059\u3002 WordPress\u306e\u8a18\u4e8b\u306f\u300eXML\u30a8\u30af\u30b9\u30dd\u30fc\u30c8 \u2192 Markdown\u5909\u63db \u2192 GitHub\u7ba1\u7406\u300f\u306e3\u30b9\u30c6\u30c3\u30d7\u2026<\/p>\n","protected":false},"author":1,"featured_media":1953,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[606],"tags":[1090,1085,1091,485,1089,1087,1092,1086,607,1088],"class_list":["post-1951","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-606","tag-github","tag-markdown","tag-python-","tag-wordpress","tag-wordpress-","tag-xml","tag-1092","tag-1086","tag-607","tag-1088"],"_links":{"self":[{"href":"https:\/\/syuji-engineer.com\/index.php?rest_route=\/wp\/v2\/posts\/1951","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/syuji-engineer.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/syuji-engineer.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/syuji-engineer.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/syuji-engineer.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1951"}],"version-history":[{"count":1,"href":"https:\/\/syuji-engineer.com\/index.php?rest_route=\/wp\/v2\/posts\/1951\/revisions"}],"predecessor-version":[{"id":1952,"href":"https:\/\/syuji-engineer.com\/index.php?rest_route=\/wp\/v2\/posts\/1951\/revisions\/1952"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/syuji-engineer.com\/index.php?rest_route=\/wp\/v2\/media\/1953"}],"wp:attachment":[{"href":"https:\/\/syuji-engineer.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1951"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/syuji-engineer.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1951"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/syuji-engineer.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1951"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}