{"id":46,"date":"2025-12-09T09:56:39","date_gmt":"2025-12-09T01:56:39","guid":{"rendered":"https:\/\/wordpress-7xecc.wasmer.app\/?p=46"},"modified":"2026-01-08T14:11:30","modified_gmt":"2026-01-08T06:11:30","slug":"%e5%a4%9a%e8%ae%be%e5%a4%87%e5%90%8c%e6%97%b6%e4%ba%a4%e5%8f%89%e7%ae%a1%e7%90%86hexo%e6%9b%b4%e6%96%b0%e5%8d%9a%e5%ae%a2%ef%bc%8c%e5%a4%aa%e5%a5%bd%e7%94%a8%e4%ba%86macos-windows","status":"publish","type":"post","link":"https:\/\/joee.zz.ac\/?p=46","title":{"rendered":"\u591a\u8bbe\u5907\u540c\u65f6\u4ea4\u53c9\u7ba1\u7406Hexo\u66f4\u65b0\u535a\u5ba2\uff0c\u592a\u597d\u7528\u4e86macOS\/Windows"},"content":{"rendered":"\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" src=\"https:\/\/upload-bbs.miyoushe.com\/upload\/2025\/07\/09\/125766904\/658277d773c29a145adf0d05055ce477_4298679859740980134.webp\" alt=\"\"\/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"\u7b2c\u4e00\u90e8\u5206\uff1aGitHub-\u64cd\u4f5c\u6b65\u9aa4\">\u7b2c\u4e00\u90e8\u5206\uff1aGitHub \u64cd\u4f5c\u6b65\u9aa4<\/h3>\n\n\n\n<p>\u5728\u6b64\u6b65\u9aa4\uff0c\u8bf7\u52a1\u5fc5\u68c0\u67e5&nbsp;<code>_posts<\/code>&nbsp;\u6587\u4ef6\u5939\u4e2d\u7684\u6240\u6709&nbsp;<code>.md<\/code>&nbsp;\u6587\u4ef6\uff0c\u786e\u4fdd\u6bcf\u7bc7\u6587\u7ae0\u7684&nbsp;<code>date<\/code>&nbsp;\u5b57\u6bb5\u90fd\u662f\u5177\u4f53\u7684\u65e5\u671f\uff08\u4f8b\u5982\uff1a2024-01-01\uff09\u3002\u5982\u679c&nbsp;<code>date<\/code>&nbsp;\u5b57\u6bb5\u672a\u6307\u5b9a\u5177\u4f53\u65e5\u671f\uff0c\u6bcf\u6b21\u5728\u65b0\u7535\u8111\u4e0a\u90e8\u7f72\u65f6\uff0c\u7cfb\u7edf\u4f1a\u81ea\u52a8\u5c06\u6587\u7ae0\u65e5\u671f\u66f4\u65b0\u4e3a\u90e8\u7f72\u5f53\u5929\u7684\u65e5\u671f\uff0c\u8fd9\u5c06\u5bfc\u81f4\u6240\u6709\u6587\u7ae0\u7684\u53d1\u5e03\u65e5\u671f\u88ab\u91cd\u7f6e\uff01\u8fd9\u4e00\u70b9\u975e\u5e38\u91cd\u8981\uff0c\u8bf7\u7279\u522b\u7559\u610f\uff01\u5982\u679c\u4e0d\u662f\u786e\u5207\u65e5\u671f\uff0c\u8bf7\u5148\u4fee\u6539\u6210\u786e\u5207\u65e5\u671f\uff0c\u63a8\u9001\u540e\uff0c\u518d\u6267\u884c\u4ee5\u4e0b\u64cd\u4f5c\uff01<\/p>\n\n\n\n<figure class=\"wp-block-image\"><a href=\"https:\/\/13fe9ff.webp.li\/2024\/11\/19456a68325b2e83ce5e0f747eaaaded.png\"><img decoding=\"async\" src=\"https:\/\/13fe9ff.webp.li\/2024\/11\/19456a68325b2e83ce5e0f747eaaaded.png\" alt=\"abm\"\/><\/a><\/figure>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>\u521b\u5efa\u4e00\u4e2a hexo \u5206\u652f<\/strong><\/li>\n<\/ol>\n\n\n\n<figure class=\"wp-block-image\"><a href=\"https:\/\/13fe9ff.webp.li\/2024\/11\/c45726a9239c407c93c49ad7101ac353.JPG\"><img decoding=\"async\" src=\"https:\/\/13fe9ff.webp.li\/2024\/11\/c45726a9239c407c93c49ad7101ac353.JPG\" alt=\"abm\"\/><\/a><\/figure>\n\n\n\n<ol start=\"2\" class=\"wp-block-list\">\n<li><strong>\u5c06 hexo \u5206\u652f\u8bbe\u7f6e\u4e3a\u9ed8\u8ba4\u5206\u652f<\/strong><\/li>\n<\/ol>\n\n\n\n<figure class=\"wp-block-image\"><a href=\"https:\/\/13fe9ff.webp.li\/2024\/11\/4d3e6b59f6afee389b547b6c2ee481c6.png\"><img decoding=\"async\" src=\"https:\/\/13fe9ff.webp.li\/2024\/11\/4d3e6b59f6afee389b547b6c2ee481c6.png\" alt=\"abm\"\/><\/a><\/figure>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"\u7b2c\u4e8c\u90e8\u5206\uff1a\u65e7\u7535\u8111\u4e0a\u7684\u64cd\u4f5c\u6b65\u9aa4\"><a href=\"https:\/\/www.limin.studio\/2024\/11\/10\/wzbk3\/#%E7%AC%AC%E4%BA%8C%E9%83%A8%E5%88%86%EF%BC%9A%E6%97%A7%E7%94%B5%E8%84%91%E4%B8%8A%E7%9A%84%E6%93%8D%E4%BD%9C%E6%AD%A5%E9%AA%A4\"><\/a>\u7b2c\u4e8c\u90e8\u5206\uff1a\u65e7\u7535\u8111\u4e0a\u7684\u64cd\u4f5c\u6b65\u9aa4<\/h3>\n\n\n\n<p><strong>\u6b65\u9aa4\u4e00\uff1a\u51c6\u5907\u8981\u4e0a\u4f20\u5230 GitHub \u7684\u6587\u4ef6<\/strong><\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>\u514b\u9686\u4ed3\u5e93\uff1a\u4e0b\u8f7d\u4ed3\u5e93\u7684 hexo \u9ed8\u8ba4\u5206\u652f\u6587\u4ef6\uff0c\u8bb0\u5f97\u5c06&nbsp;<code>username<\/code>&nbsp;\u66ff\u6362\u4e3a\u4f60\u81ea\u5df1\u7684 GitHub \u7528\u6237\u540d\uff1agit clone git@github.com:username\/username.github.io.git<\/li>\n\n\n\n<li>\u6253\u5305\u6587\u4ef6\uff1a\u8fdb\u5165\u514b\u9686\u7684\u6587\u4ef6\u5939\uff0c\u4fdd\u7559&nbsp;<code>.git<\/code>&nbsp;\u6587\u4ef6\u5939\uff0c\u5220\u9664\u5176\u4ed6\u6587\u4ef6\u3002<\/li>\n\n\n\n<li>\u6574\u7406\u6587\u4ef6\uff1a\u627e\u5230\u4e4b\u524d\u7684 hexo \u6587\u4ef6\u5939\uff0c\u5c06\u5176\u4e2d&nbsp;<code>.deploy_git<\/code>&nbsp;\u6587\u4ef6\u5939\u5916\u7684\u6240\u6709\u5185\u5bb9\u590d\u5236\u5230\u514b\u9686\u7684\u6587\u4ef6\u5939\u4e2d\u3002<\/li>\n\n\n\n<li><strong>\u8bbe\u7f6e .gitignore \u6587\u4ef6<\/strong>\uff1a\u786e\u8ba4\u514b\u9686\u6587\u4ef6\u5939\u5185\u6709&nbsp;<code>.gitignore<\/code>&nbsp;\u6587\u4ef6\uff0c\u5b83\u7528\u4e8e\u5ffd\u7565\u4e00\u4e9b\u4e0d\u9700\u8981\u7684\u6587\u4ef6\u7c7b\u578b\uff08\u82e5\u6ca1\u6709\uff0c\u9700\u624b\u52a8\u521b\u5efa\uff09\u3002\u5185\u5bb9\u5982\u4e0b\uff1a.DS_Store<br>Thumbs.db<br>db.json<br>*.log<br>node_modules\/<br>public\/<br>.deploy*\/<\/li>\n\n\n\n<li>\u68c0\u67e5\u4e3b\u9898\u6587\u4ef6\u5939\uff1a\u5982\u679c\u5df2\u514b\u9686\u4e3b\u9898\u6587\u4ef6\u5939\uff0c\u9700\u8981\u5220\u9664&nbsp;<code>.git<\/code>&nbsp;\u6587\u4ef6\uff0c\u56e0\u4e3a Git \u4e0d\u80fd\u5d4c\u5957\u7248\u672c\u63a7\u5236\u3002\u786e\u4fdd\u663e\u793a\u9690\u85cf\u6587\u4ef6\uff0c\u907f\u514d\u4e0a\u4f20\u51fa\u9519\uff0c\u5f71\u54cd\u914d\u7f6e\u540c\u6b65\u3002<\/li>\n<\/ol>\n\n\n\n<p><strong>\u6b65\u9aa4\u4e8c\uff1a\u5c06\u4fee\u6539\u540e\u7684\u6587\u4ef6\u63a8\u9001\u5230\u8fdc\u7a0b\u4ed3\u5e93<\/strong><\/p>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><td>git add .<br>git commit -m &#8220;add_branch&#8221;<br>git push<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>\u6b64\u65f6\uff0c\u60a8\u5df2\u5c06\u5b8c\u6574\u7684\u7ad9\u70b9\u63a8\u9001\u5230\u8fdc\u7a0b\u4ed3\u5e93\u7684 hexo \u9ed8\u8ba4\u5206\u652f\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"\u7b2c\u4e09\u90e8\u5206\uff1a\u65b0\u7535\u8111\u4e0a\u7684\u64cd\u4f5c\u6b65\u9aa4\"><a href=\"https:\/\/www.limin.studio\/2024\/11\/10\/wzbk3\/#%E7%AC%AC%E4%B8%89%E9%83%A8%E5%88%86%EF%BC%9A%E6%96%B0%E7%94%B5%E8%84%91%E4%B8%8A%E7%9A%84%E6%93%8D%E4%BD%9C%E6%AD%A5%E9%AA%A4\"><\/a>\u7b2c\u4e09\u90e8\u5206\uff1a\u65b0\u7535\u8111\u4e0a\u7684\u64cd\u4f5c\u6b65\u9aa4<\/h3>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>\u914d\u7f6e SSH \u5bc6\u94a5<\/strong>\uff1a\u5728\u65b0\u7535\u8111\u4e0a\u751f\u6210\u5e76\u6dfb\u52a0 SSH \u5bc6\u94a5\u5230 GitHub \u8d26\u6237\u4e0a\u3002<\/li>\n\n\n\n<li><strong>\u514b\u9686\u4ed3\u5e93<\/strong>\uff1a\u521b\u5efa\u4e00\u4e2a\u6587\u4ef6\u5939\uff08\u5047\u8bbe\u547d\u540d\u4e3a A\uff09\uff0c\u5728 A \u6587\u4ef6\u5939\u5185\u6253\u5f00\u7ec8\u7aef\uff0c\u5e76\u6267\u884c\u4ee5\u4e0b\u547d\u4ee4\uff08\u66ff\u6362&nbsp;<code>username<\/code>&nbsp;\u4e3a\u4f60\u7684 GitHub \u7528\u6237\u540d\uff09\uff1agit clone git@github.com:username\/username.github.io.git &#8211;depth=1<\/li>\n\n\n\n<li><strong>\u5b89\u88c5 Hexo \u73af\u5883<\/strong>\uff1a\u8fdb\u5165&nbsp;<code>username.github.io<\/code>&nbsp;\u6587\u4ef6\u5939\u5e76\u8fd0\u884c\u4ee5\u4e0b\u547d\u4ee4\uff1anpm install hexo<br>npm install<br>npm install hexo-deployer-git<\/li>\n<\/ol>\n\n\n\n<p>\u81f3\u6b64\uff0c\u60a8\u53ef\u4ee5\u5728\u65b0\u7535\u8111\u4e0a\u5f00\u59cb\u7f16\u8f91\u548c\u53d1\u5e03\u6587\u7ae0\u4e86\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"\u7b2c\u56db\u90e8\u5206\uff1a\u6ce8\u610f\u4e8b\u9879\"><a href=\"https:\/\/www.limin.studio\/2024\/11\/10\/wzbk3\/#%E7%AC%AC%E5%9B%9B%E9%83%A8%E5%88%86%EF%BC%9A%E6%B3%A8%E6%84%8F%E4%BA%8B%E9%A1%B9\"><\/a>\u7b2c\u56db\u90e8\u5206\uff1a\u6ce8\u610f\u4e8b\u9879<\/h3>\n\n\n\n<p>\u5f53\u60a8\u5728\u65e7\u7535\u8111\u548c\u65b0\u7535\u8111\u4e0a\u4ea4\u66ff\u4f7f\u7528\u65f6\uff0c\u6ce8\u610f\u4fdd\u6301\u540c\u6b65\uff1a<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>\u65e7\u7535\u8111\uff08\u7532\uff09<\/strong>\uff1a\u5728\u201c\u7532\u201d\u7535\u8111\u4e0a\u5b8c\u6210\u6587\u7ae0\u66f4\u65b0\u540e\uff0c\u8bb0\u5f97\u8fd0\u884c\uff1agit add .<br>git commit -m &#8220;add_branch&#8221;<br>git push<br>\u8fd9\u6837 GitHub \u4e0a\u5c06\u62e5\u6709\u6700\u65b0\u7248\u672c\u7684\u6587\u4ef6\u3002<\/li>\n\n\n\n<li><strong>\u65b0\u7535\u8111\uff08\u4e59\uff09<\/strong>\uff1a\u4e0b\u5348\u5728\u201c\u4e59\u201d\u7535\u8111\u4e0a\u7ee7\u7eed\u7f16\u8f91\u65f6\uff0c\u5148\u6267\u884c\u4ee5\u4e0b\u547d\u4ee4\u4ee5\u540c\u6b65\u6700\u65b0\u6587\u4ef6\uff1agit pull<br>\u68c0\u67e5\u6587\u4ef6\u548c\u9884\u89c8\u662f\u5426\u662f\u6700\u65b0\u7248\u672c\uff0c\u786e\u8ba4\u65e0\u8bef\u540e\u7ee7\u7eed\u64b0\u5199\u3002\u5982\u679c\u6709\u95ee\u9898\uff0c\u6309\u7167\u201c\u7b2c\u4e8c\u90e8\u5206\u201d\u7684\u64cd\u4f5c\u91cd\u65b0\u8fdb\u884c\u540c\u6b65\u3002<\/li>\n<\/ul>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p><strong>\u6ce8\u610f<\/strong>\uff1a\u5982\u679c\u4e00\u53f0\u7535\u8111\u957f\u65f6\u95f4\u672a\u4f7f\u7528\uff0c\u53ef\u80fd\u4f1a\u5bfc\u81f4\u540c\u6b65\u5931\u6548\uff0c\u5efa\u8bae\u6309\u7167\u201c\u7b2c\u4e8c\u90e8\u5206\u201d\u7684\u6b65\u9aa4\u91cd\u65b0\u64cd\u4f5c\u3002<\/p>\n<\/blockquote>\n\n\n\n<p>\u5982\u679c\u6709\u5176\u4ed6\u95ee\u9898\uff0c\u6b22\u8fce\u52a0\u5165\u6211\u7684\u7535\u62a5\u7fa4\u8ba8\u8bba\u4ea4\u6d41\u3002<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"\u7b2c\u4e94\u90e8\u5206\uff1a\u5e38\u7528\u6307\u4ee4\u5217\u8868\"><a href=\"https:\/\/www.limin.studio\/2024\/11\/10\/wzbk3\/#%E7%AC%AC%E4%BA%94%E9%83%A8%E5%88%86%EF%BC%9A%E5%B8%B8%E7%94%A8%E6%8C%87%E4%BB%A4%E5%88%97%E8%A1%A8\"><\/a>\u7b2c\u4e94\u90e8\u5206\uff1a\u5e38\u7528\u6307\u4ee4\u5217\u8868<\/h3>\n\n\n\n<p>\u4ee5\u4e0b\u6307\u4ee4\u5728\u64cd\u4f5c\u8fc7\u7a0b\u4e2d\u4f1a\u9891\u7e41\u4f7f\u7528\uff0c\u8bb0\u5f97\u66ff\u6362&nbsp;<code>username<\/code>&nbsp;\u4e3a\u60a8\u7684 GitHub \u7528\u6237\u540d\uff1a<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><td>hexo cl; hexo s<br><br>hexo cl; hexo g; hexo d<br><br>git clone git@github.com:username\/username.github.io.git<br><br>git add .<br>git commit -m &#8220;add_branch&#8221;<br>git push<br><br>git clone git@github.com:username\/username.github.io.git &#8211;depth=1<br><br>npm install hexo<br>npm install<br>npm install hexo-deployer-git<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p><a href=\"https:\/\/www.limin.studio\/2024\/11\/10\/wzbk3\/#%E6%9C%80%E5%90%8E%E5%A4%A7%E5%AE%B6%EF%BC%8C%E6%97%A0%E8%AE%BA%E5%9C%A8%E5%93%AA%E4%B8%80%E5%8F%B0%E7%94%B5%E8%84%91%E4%B8%8A%E6%9B%B4%E6%96%B0%E5%95%A6%E6%96%87%E7%AB%A0%EF%BC%8C%E9%83%BD%E6%98%AF%E6%89%A7%E8%A1%8C%E6%8E%A8%E9%80%81%E5%88%B0GitHub%E7%9A%84%E6%8C%87%E4%BB%A4%EF%BC%81\"><\/a>\u6700\u540e\u5927\u5bb6\uff0c\u65e0\u8bba\u5728\u54ea\u4e00\u53f0\u7535\u8111\u4e0a\u66f4\u65b0\u5566\u6587\u7ae0\uff0c\u90fd\u662f\u6267\u884c\u63a8\u9001\u5230GitHub\u7684\u6307\u4ee4\uff01<\/p>\n\n\n\n<p>\uff01\uff01\uff01 \u8f6c\u8f7d\u6765\u81ea&nbsp;<a href=\"https:\/\/www.limin.studio\/2024\/11\/10\/wzbk3\/\" target=\"_blank\" rel=\"noreferrer noopener\">Limin Studio<\/a> \uff01\uff01\uff01<\/p>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u7b2c\u4e00\u90e8\u5206\uff1aGitHub \u64cd\u4f5c\u6b65\u9aa4 \u5728\u6b64\u6b65\u9aa4\uff0c\u8bf7\u52a1\u5fc5\u68c0\u67e5&nbsp;_posts&nbsp;\u6587\u4ef6\u5939\u4e2d\u7684\u6240\u6709&nbsp;.md&nbsp;\u6587\u4ef6\uff0c\u786e\u4fdd\u6bcf\u7bc7\u6587\u7ae0\u7684&#038;nb&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[15,16],"class_list":["post-46","post","type-post","status-publish","format-standard","hentry","category-categorized","tag-15","tag-16"],"_links":{"self":[{"href":"https:\/\/joee.zz.ac\/index.php?rest_route=\/wp\/v2\/posts\/46","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/joee.zz.ac\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/joee.zz.ac\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/joee.zz.ac\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/joee.zz.ac\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=46"}],"version-history":[{"count":0,"href":"https:\/\/joee.zz.ac\/index.php?rest_route=\/wp\/v2\/posts\/46\/revisions"}],"wp:attachment":[{"href":"https:\/\/joee.zz.ac\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=46"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/joee.zz.ac\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=46"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/joee.zz.ac\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=46"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}