{"componentChunkName":"component---node-modules-gatsby-theme-gine-blog-src-components-post-blog-post-js","path":"/posts/11bcf166f7244997adeee93b5ea0a764","webpackCompilationHash":"abbc32fa0c65a814f292","result":{"data":{"siteConfig":{"title":"812lcl's Blog","commentDisqusShortname":"812lcl-notion-blog","commentOpen":true},"posts":{"public_date":"2013-10-25","name":"Octopress博客搭建及目录结构","tags":["Octopress","Blog"],"html":"<div data-block-id=\"48747628-9313-4f5f-b28b-1a3ec021419d\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 2px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">搭建个人博客的想法有一段时间了，不是认为自己有多牛，而是想通过写博客记录并反思自己的学习历程，能使学过的东西更具条理，慢慢形成自己的知识体系。但自己租个服务器，买个域名，一点一点搭建一个网站成本又太大，我对HTML、javascript、css等前端技术了解有限，网站搭建很多技术也知之甚少。但后来Jekyll、Octopress、GitHub pages让我搭建个人博客成为了可能。</div></div></div></div><div data-block-id=\"7400aa36-7d34-4e5c-8f4e-7ccfe6f33355\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">最终选择了octopress，也是因为他的简单，他基于Jekyll，处理了Jekyll的很多麻烦设置，也不需要对前端技术有很深的了解，从一开始什么也没有，到搭建起一个可用的博客只需花费十几分钟，十分方便，虽然想要配置齐自己想要的东西还是需要一番折腾的，但那是后话了。</div></div></div></div><div data-block-id=\"57ca4b1c-e642-4283-aa29-944e76ddec7e\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">我的搭建环境是ubuntu 13.04，不同的系统需要作出相应的修改，但变化不大。我的博客中添加了3D标签、微博秀、豆瓣读书、相关文章推荐、访客地图、评论分享、文章热度排名等等很多东西，本文主要介绍简单博客的搭建和目录结构，之后会写篇文章介绍各个模块的搭建。</div></div></div></div><div data-block-id=\"43a5f2e0-f264-494e-b333-aea32a8c6771\" class=\"notion-selectable notion-sub_header-block\" style=\"width: 100%; max-width: 608px; margin-top: 1.4em; margin-bottom: 1px; color: rgb(55, 53, 47);\"><div style=\"display: flex; width: 100%; font-weight: 600; font-size: 1.5em; line-height: 1.3; color: inherit; fill: inherit;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\"Heading 2\" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">开始搭建</div></div></div><div data-block-id=\"d522c29c-3ff3-4648-861a-83d284104bd6\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">Octopress博客是搭建在github上的静态网页，octopress相当于一个自动化生成静态网页的工具，网页并没有使用数据库等，使用的是github提供的服务器和域名。github pages为每个用户提供一个名为<span style=\"font-family:&quot;SFMono-Regular&quot;, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace;line-height:normal;background:rgba(135,131,120,0.15);color:#EB5757;border-radius:3px;font-size:85%;padding:0.2em 0.4em\" data-token-index=\"1\">http://username.github.com</span>的域名。你首先需要在github上建立一个名为<span style=\"font-family:&quot;SFMono-Regular&quot;, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace;line-height:normal;background:rgba(135,131,120,0.15);color:#EB5757;border-radius:3px;font-size:85%;padding:0.2em 0.4em\" data-token-index=\"3\">username.github.com</span>的仓库，之后的博客将会部署到这个仓库中，部署成后你就可以从<span style=\"font-family:&quot;SFMono-Regular&quot;, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace;line-height:normal;background:rgba(135,131,120,0.15);color:#EB5757;border-radius:3px;font-size:85%;padding:0.2em 0.4em\" data-token-index=\"5\">http://username.github.com</span>访问你的博客了，不过可能需要等待十分钟。</div></div></div></div><div data-block-id=\"7ad4fbb1-e4fb-488b-99b5-525d066dea01\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">利用到了github，所以首先应该配置好你的git环境，包括安装git，创建ssh公私钥与github建立信任连接，设置github用户名和邮箱，如果你不熟悉可以参考<a href=\"http://www.worldhello.net/gotgithub/index.html\" style=\"text-decoration:underline;color:inherit;cursor:pointer;word-wrap:break-word\" target=\"_blank\" rel=\"noopener noreferrer\" data-token-index=\"1\">GotGitHub</a>。当然你还有熟悉git的基本操作了，<a href=\"http://rogerdudler.github.io/git-guide/index.zh.html\" style=\"text-decoration:underline;color:inherit;cursor:pointer;word-wrap:break-word\" target=\"_blank\" rel=\"noopener noreferrer\" data-token-index=\"3\">这里</a>是一个简易教程。</div></div></div></div><div data-block-id=\"911c7c4d-b507-423f-b3db-1fddf2ad75d3\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">octopress和jekyll都是依赖于Ruby的，所以如果你没装，先要装一下它咯。octopress 2.0是依赖于Ruby 1.9.3版本的，所以我们指明版本安装：</div></div></div></div><div data-block-id=\"cc6a3f19-553f-4a93-9f0f-a17c7c682464\" class=\"notion-selectable notion-code-block\" style=\"width: 100%; max-width: 608px; margin-top: 4px; margin-bottom: 4px;\"><div style=\"display: flex;\"><div style=\"flex-grow: 1; border-radius: 3px; text-align: left; position: relative; background: rgb(247, 246, 243); min-width: 0px; width: 100%;\"><div class=\"line-numbers notion-code-block\" style=\"display: flex; overflow-x: auto;\"><div contenteditable=\"false\" spellcheck=\"false\" autocorrect=\"off\" autocapitalize=\"off\" data-root=\"true\" style=\"flex-grow: 1; flex-shrink: 1; text-align: left; font-family: SFMono-Regular, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace; font-size: 85%; tab-size: 2; padding: 30px 16px 30px 20px; min-height: 1em; color: rgb(55, 53, 47); white-space: pre;\">sudo apt-get install ruby1.9.3<span>\n</span></div></div><div style=\"position: absolute; top: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"></div><div style=\"position: absolute; bottom: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"><div role=\"button\" aria-disabled=\"true\" tabindex=\"-1\" style=\"user-select: none; transition: background 120ms ease-in 0s; display: inline-flex; align-items: center; white-space: nowrap; height: 20px; border-radius: 3px; font-size: 12px; line-height: 1.2; padding-left: 5px; padding-right: 5px; color: rgba(55, 53, 47, 0.6); margin-right: 5px;\">Plain Text<svg viewBox=\"0 0 30 30\" class=\"chevronDown\" style=\"width: 10px; height: 100%; display: block; fill: rgba(55, 53, 47, 0.3); flex-shrink: 0; backface-visibility: hidden; margin-left: 4px;\"><polygon points=\"15,17.4 4.8,7 2,9.8 15,23 28,9.8 25.2,7 \"></polygon></svg></div></div></div></div></div><div data-block-id=\"3f1459a0-b385-4704-8e44-e3f2f022257c\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">接下来就可以安装Octopress了，首先将octopress库clone到本地，在想要放置本地仓库的位置，建一个文件夹，文件夹名随你，比如我在$HOME/处建立了blog：</div></div></div></div><div data-block-id=\"f0f54502-1adb-4f81-8ad0-81b5c11a326a\" class=\"notion-selectable notion-code-block\" style=\"width: 100%; max-width: 608px; margin-top: 4px; margin-bottom: 4px;\"><div style=\"display: flex;\"><div style=\"flex-grow: 1; border-radius: 3px; text-align: left; position: relative; background: rgb(247, 246, 243); min-width: 0px; width: 100%;\"><div class=\"line-numbers notion-code-block\" style=\"display: flex; overflow-x: auto;\"><div contenteditable=\"false\" spellcheck=\"false\" autocorrect=\"off\" autocapitalize=\"off\" data-root=\"true\" style=\"flex-grow: 1; flex-shrink: 1; text-align: left; font-family: SFMono-Regular, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace; font-size: 85%; tab-size: 2; padding: 30px 16px 30px 20px; min-height: 1em; color: rgb(55, 53, 47); white-space: pre;\">$ cd ~\n$ mkdir blog\n$ git clone git://github.com/imathis/octopress.git blog<span>\n</span></div></div><div style=\"position: absolute; top: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"></div><div style=\"position: absolute; bottom: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"><div role=\"button\" aria-disabled=\"true\" tabindex=\"-1\" style=\"user-select: none; transition: background 120ms ease-in 0s; display: inline-flex; align-items: center; white-space: nowrap; height: 20px; border-radius: 3px; font-size: 12px; line-height: 1.2; padding-left: 5px; padding-right: 5px; color: rgba(55, 53, 47, 0.6); margin-right: 5px;\">Plain Text<svg viewBox=\"0 0 30 30\" class=\"chevronDown\" style=\"width: 10px; height: 100%; display: block; fill: rgba(55, 53, 47, 0.3); flex-shrink: 0; backface-visibility: hidden; margin-left: 4px;\"><polygon points=\"15,17.4 4.8,7 2,9.8 15,23 28,9.8 25.2,7 \"></polygon></svg></div></div></div></div></div><div data-block-id=\"2414218e-f2bf-4e66-8c38-8edd6107a82c\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">然后进入仓库，安装其他的依赖环境：</div></div></div></div><div data-block-id=\"4b1fca31-11ba-400a-a6a4-97ce3e3c8573\" class=\"notion-selectable notion-code-block\" style=\"width: 100%; max-width: 608px; margin-top: 4px; margin-bottom: 4px;\"><div style=\"display: flex;\"><div style=\"flex-grow: 1; border-radius: 3px; text-align: left; position: relative; background: rgb(247, 246, 243); min-width: 0px; width: 100%;\"><div class=\"line-numbers notion-code-block\" style=\"display: flex; overflow-x: auto;\"><div contenteditable=\"false\" spellcheck=\"false\" autocorrect=\"off\" autocapitalize=\"off\" data-root=\"true\" style=\"flex-grow: 1; flex-shrink: 1; text-align: left; font-family: SFMono-Regular, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace; font-size: 85%; tab-size: 2; padding: 30px 16px 30px 20px; min-height: 1em; color: rgb(55, 53, 47); white-space: pre;\">$ cd blog\n$ sudo gem install bundler\n$ rbenv rehash\n$ bundle install        #根据Gemfile安装依赖的工具，需要耐心等待<span>\n</span></div></div><div style=\"position: absolute; top: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"></div><div style=\"position: absolute; bottom: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"><div role=\"button\" aria-disabled=\"true\" tabindex=\"-1\" style=\"user-select: none; transition: background 120ms ease-in 0s; display: inline-flex; align-items: center; white-space: nowrap; height: 20px; border-radius: 3px; font-size: 12px; line-height: 1.2; padding-left: 5px; padding-right: 5px; color: rgba(55, 53, 47, 0.6); margin-right: 5px;\">Plain Text<svg viewBox=\"0 0 30 30\" class=\"chevronDown\" style=\"width: 10px; height: 100%; display: block; fill: rgba(55, 53, 47, 0.3); flex-shrink: 0; backface-visibility: hidden; margin-left: 4px;\"><polygon points=\"15,17.4 4.8,7 2,9.8 15,23 28,9.8 25.2,7 \"></polygon></svg></div></div></div></div></div><div data-block-id=\"a8563024-a9ff-4a56-a8c4-358b4c1924f3\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">安装默认主题</div></div></div></div><div data-block-id=\"de9ad46c-616d-4023-b137-79a05431f21d\" class=\"notion-selectable notion-code-block\" style=\"width: 100%; max-width: 608px; margin-top: 4px; margin-bottom: 4px;\"><div style=\"display: flex;\"><div style=\"flex-grow: 1; border-radius: 3px; text-align: left; position: relative; background: rgb(247, 246, 243); min-width: 0px; width: 100%;\"><div class=\"line-numbers notion-code-block\" style=\"display: flex; overflow-x: auto;\"><div contenteditable=\"false\" spellcheck=\"false\" autocorrect=\"off\" autocapitalize=\"off\" data-root=\"true\" style=\"flex-grow: 1; flex-shrink: 1; text-align: left; font-family: SFMono-Regular, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace; font-size: 85%; tab-size: 2; padding: 30px 16px 30px 20px; min-height: 1em; color: rgb(55, 53, 47); white-space: pre;\">rake install<span>\n</span></div></div><div style=\"position: absolute; top: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"></div><div style=\"position: absolute; bottom: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"><div role=\"button\" aria-disabled=\"true\" tabindex=\"-1\" style=\"user-select: none; transition: background 120ms ease-in 0s; display: inline-flex; align-items: center; white-space: nowrap; height: 20px; border-radius: 3px; font-size: 12px; line-height: 1.2; padding-left: 5px; padding-right: 5px; color: rgba(55, 53, 47, 0.6); margin-right: 5px;\">Plain Text<svg viewBox=\"0 0 30 30\" class=\"chevronDown\" style=\"width: 10px; height: 100%; display: block; fill: rgba(55, 53, 47, 0.3); flex-shrink: 0; backface-visibility: hidden; margin-left: 4px;\"><polygon points=\"15,17.4 4.8,7 2,9.8 15,23 28,9.8 25.2,7 \"></polygon></svg></div></div></div></div></div><div data-block-id=\"d8eec0bf-461f-4550-8dbd-204a3987ec27\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">现在octopress安装完成，但还没有生成静态网页，还没有将其部署到网上，要设置博客使用的REPOSITORY了：</div></div></div></div><div data-block-id=\"2e13f8a8-a2f3-4ab7-bbd6-e5670ec09aea\" class=\"notion-selectable notion-code-block\" style=\"width: 100%; max-width: 608px; margin-top: 4px; margin-bottom: 4px;\"><div style=\"display: flex;\"><div style=\"flex-grow: 1; border-radius: 3px; text-align: left; position: relative; background: rgb(247, 246, 243); min-width: 0px; width: 100%;\"><div class=\"line-numbers notion-code-block\" style=\"display: flex; overflow-x: auto;\"><div contenteditable=\"false\" spellcheck=\"false\" autocorrect=\"off\" autocapitalize=\"off\" data-root=\"true\" style=\"flex-grow: 1; flex-shrink: 1; text-align: left; font-family: SFMono-Regular, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace; font-size: 85%; tab-size: 2; padding: 30px 16px 30px 20px; min-height: 1em; color: rgb(55, 53, 47); white-space: pre;\">$ rake setup_github_pages\nEnter the read/write url for your repository\n(For example, 'git@github.com:your_username/your_username.github.com')\nRepository url:<span>\n</span></div></div><div style=\"position: absolute; top: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"></div><div style=\"position: absolute; bottom: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"><div role=\"button\" aria-disabled=\"true\" tabindex=\"-1\" style=\"user-select: none; transition: background 120ms ease-in 0s; display: inline-flex; align-items: center; white-space: nowrap; height: 20px; border-radius: 3px; font-size: 12px; line-height: 1.2; padding-left: 5px; padding-right: 5px; color: rgba(55, 53, 47, 0.6); margin-right: 5px;\">Plain Text<svg viewBox=\"0 0 30 30\" class=\"chevronDown\" style=\"width: 10px; height: 100%; display: block; fill: rgba(55, 53, 47, 0.3); flex-shrink: 0; backface-visibility: hidden; margin-left: 4px;\"><polygon points=\"15,17.4 4.8,7 2,9.8 15,23 28,9.8 25.2,7 \"></polygon></svg></div></div></div></div></div><div data-block-id=\"8ff9e52e-1ee8-4bf7-8db1-f989ba749fca\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">请输入：git@github.com:yourname/yourname.github.com.git (将yourname替换成你的github登录名)</div></div></div></div><div data-block-id=\"ee93c237-4c70-40e5-b9a4-ca219dda7218\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">这个步骤rake会做很多事情：</div></div></div></div><div data-block-id=\"ed1160eb-fc6e-4280-ad82-b68bf7337349\" class=\"notion-selectable notion-numbered_list-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"display: flex; align-items: flex-start; width: 100%; padding-left: 2px; color: inherit; fill: inherit;\"><div style=\"margin-right: 4px; width: 24px; display: flex; align-items: center; justify-content: center; flex-grow: 0; flex-shrink: 0; min-height: calc((1.5em + 3px) + 3px);\"><span>1.</span></div><div style=\"flex: 1 1 0px; min-width: 1px; display: flex; flex-direction: column;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\"List\" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding-top: 3px; padding-bottom: 3px; text-align: left;\">在.git/config中替换origin为你输入的repository，并把原来的origin写到octopress中。</div></div></div></div></div><div data-block-id=\"9ae530b7-1bee-4b6a-9b4e-7fd573ac610c\" class=\"notion-selectable notion-numbered_list-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"display: flex; align-items: flex-start; width: 100%; padding-left: 2px; color: inherit; fill: inherit;\"><div style=\"margin-right: 4px; width: 24px; display: flex; align-items: center; justify-content: center; flex-grow: 0; flex-shrink: 0; min-height: calc((1.5em + 3px) + 3px);\"><span>2.</span></div><div style=\"flex: 1 1 0px; min-width: 1px; display: flex; flex-direction: column;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\"List\" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding-top: 3px; padding-bottom: 3px; text-align: left;\">创建新的branch source并切换到这个branch。</div></div></div></div></div><div data-block-id=\"120eb09b-001b-46db-a7d3-eedc55bc004d\" class=\"notion-selectable notion-numbered_list-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"display: flex; align-items: flex-start; width: 100%; padding-left: 2px; color: inherit; fill: inherit;\"><div style=\"margin-right: 4px; width: 24px; display: flex; align-items: center; justify-content: center; flex-grow: 0; flex-shrink: 0; min-height: calc((1.5em + 3px) + 3px);\"><span>3.</span></div><div style=\"flex: 1 1 0px; min-width: 1px; display: flex; flex-direction: column;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\"List\" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding-top: 3px; padding-bottom: 3px; text-align: left;\">在生成的_deploy目录下，初始化git repository为你的repository。</div></div></div></div></div><div data-block-id=\"a968f926-6f09-4d9b-be90-a0ad931c2fa9\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">接下来就可以生成静态网页，并将其部署到github上了，只需如下两句：</div></div></div></div><div data-block-id=\"a84cec10-a3f3-4715-93ab-88872e591c60\" class=\"notion-selectable notion-code-block\" style=\"width: 100%; max-width: 608px; margin-top: 4px; margin-bottom: 4px;\"><div style=\"display: flex;\"><div style=\"flex-grow: 1; border-radius: 3px; text-align: left; position: relative; background: rgb(247, 246, 243); min-width: 0px; width: 100%;\"><div class=\"line-numbers notion-code-block\" style=\"display: flex; overflow-x: auto;\"><div contenteditable=\"false\" spellcheck=\"false\" autocorrect=\"off\" autocapitalize=\"off\" data-root=\"true\" style=\"flex-grow: 1; flex-shrink: 1; text-align: left; font-family: SFMono-Regular, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace; font-size: 85%; tab-size: 2; padding: 30px 16px 30px 20px; min-height: 1em; color: rgb(55, 53, 47); white-space: pre;\">rake generate   #生成静态网页\nrake deploy     #发布网页<span>\n</span></div></div><div style=\"position: absolute; top: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"></div><div style=\"position: absolute; bottom: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"><div role=\"button\" aria-disabled=\"true\" tabindex=\"-1\" style=\"user-select: none; transition: background 120ms ease-in 0s; display: inline-flex; align-items: center; white-space: nowrap; height: 20px; border-radius: 3px; font-size: 12px; line-height: 1.2; padding-left: 5px; padding-right: 5px; color: rgba(55, 53, 47, 0.6); margin-right: 5px;\">Plain Text<svg viewBox=\"0 0 30 30\" class=\"chevronDown\" style=\"width: 10px; height: 100%; display: block; fill: rgba(55, 53, 47, 0.3); flex-shrink: 0; backface-visibility: hidden; margin-left: 4px;\"><polygon points=\"15,17.4 4.8,7 2,9.8 15,23 28,9.8 25.2,7 \"></polygon></svg></div></div></div></div></div><div data-block-id=\"114dc5a1-5c77-4f27-94ca-463a2e4bff13\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">等待几分钟后，网页就已经部署好了，你可以访问你的域名查看自己的博客了。然后可以将源码添加到github中进行管理，你仓库中有两个分支，master分支是静态网页，source分支则是你的生成网页的源码，这样在另一台电脑上你可以clone你的仓库，很容易的进行你的博客编写。</div></div></div></div><div data-block-id=\"f5b6d0c2-507d-4f6d-be20-25ae1bedaed6\" class=\"notion-selectable notion-code-block\" style=\"width: 100%; max-width: 608px; margin-top: 4px; margin-bottom: 4px;\"><div style=\"display: flex;\"><div style=\"flex-grow: 1; border-radius: 3px; text-align: left; position: relative; background: rgb(247, 246, 243); min-width: 0px; width: 100%;\"><div class=\"line-numbers notion-code-block\" style=\"display: flex; overflow-x: auto;\"><div contenteditable=\"false\" spellcheck=\"false\" autocorrect=\"off\" autocapitalize=\"off\" data-root=\"true\" style=\"flex-grow: 1; flex-shrink: 1; text-align: left; font-family: SFMono-Regular, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace; font-size: 85%; tab-size: 2; padding: 30px 16px 30px 20px; min-height: 1em; color: rgb(55, 53, 47); white-space: pre;\">git add .\ngit commit -m 'init'\ngit push origin source<span>\n</span></div></div><div style=\"position: absolute; top: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"></div><div style=\"position: absolute; bottom: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"><div role=\"button\" aria-disabled=\"true\" tabindex=\"-1\" style=\"user-select: none; transition: background 120ms ease-in 0s; display: inline-flex; align-items: center; white-space: nowrap; height: 20px; border-radius: 3px; font-size: 12px; line-height: 1.2; padding-left: 5px; padding-right: 5px; color: rgba(55, 53, 47, 0.6); margin-right: 5px;\">Plain Text<svg viewBox=\"0 0 30 30\" class=\"chevronDown\" style=\"width: 10px; height: 100%; display: block; fill: rgba(55, 53, 47, 0.3); flex-shrink: 0; backface-visibility: hidden; margin-left: 4px;\"><polygon points=\"15,17.4 4.8,7 2,9.8 15,23 28,9.8 25.2,7 \"></polygon></svg></div></div></div></div></div><div data-block-id=\"4cedd2d8-5089-4cc6-a4f0-4302a4afa06a\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">现在就可以进行文章的编写了，编写文章使用markdown语法，十分便捷，语法简单，可参见<a href=\"http://wowubuntu.com/markdown/index.html#code\" style=\"text-decoration:underline;color:inherit;cursor:pointer;word-wrap:break-word\" target=\"_blank\" rel=\"noopener noreferrer\" data-token-index=\"1\">markdown语法说明</a>。输入如下命令：</div></div></div></div><div data-block-id=\"9f4f51de-1524-4fac-80af-c61c8f5d5b3c\" class=\"notion-selectable notion-code-block\" style=\"width: 100%; max-width: 608px; margin-top: 4px; margin-bottom: 4px;\"><div style=\"display: flex;\"><div style=\"flex-grow: 1; border-radius: 3px; text-align: left; position: relative; background: rgb(247, 246, 243); min-width: 0px; width: 100%;\"><div class=\"line-numbers notion-code-block\" style=\"display: flex; overflow-x: auto;\"><div contenteditable=\"false\" spellcheck=\"false\" autocorrect=\"off\" autocapitalize=\"off\" data-root=\"true\" style=\"flex-grow: 1; flex-shrink: 1; text-align: left; font-family: SFMono-Regular, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace; font-size: 85%; tab-size: 2; padding: 30px 16px 30px 20px; min-height: 1em; color: rgb(55, 53, 47); white-space: pre;\">rake new_post['title']<span>\n</span></div></div><div style=\"position: absolute; top: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"></div><div style=\"position: absolute; bottom: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"><div role=\"button\" aria-disabled=\"true\" tabindex=\"-1\" style=\"user-select: none; transition: background 120ms ease-in 0s; display: inline-flex; align-items: center; white-space: nowrap; height: 20px; border-radius: 3px; font-size: 12px; line-height: 1.2; padding-left: 5px; padding-right: 5px; color: rgba(55, 53, 47, 0.6); margin-right: 5px;\">Plain Text<svg viewBox=\"0 0 30 30\" class=\"chevronDown\" style=\"width: 10px; height: 100%; display: block; fill: rgba(55, 53, 47, 0.3); flex-shrink: 0; backface-visibility: hidden; margin-left: 4px;\"><polygon points=\"15,17.4 4.8,7 2,9.8 15,23 28,9.8 25.2,7 \"></polygon></svg></div></div></div></div></div><div data-block-id=\"5aa02a0a-9d31-4800-87d3-853a759adc03\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">在~/blog/source/_posts下回生成一个名为<span style=\"font-family:&quot;SFMono-Regular&quot;, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace;line-height:normal;background:rgba(135,131,120,0.15);color:#EB5757;border-radius:3px;font-size:85%;padding:0.2em 0.4em\" data-token-index=\"1\">YYYY-MM-DD-title.markdown</span>的文件，在这个文件中编写你的文章即可。编写完成后依然按上边发布网页的方法发布即可：</div></div></div></div><div data-block-id=\"349b49c9-b2ef-4a93-b2aa-16375f0edc14\" class=\"notion-selectable notion-code-block\" style=\"width: 100%; max-width: 608px; margin-top: 4px; margin-bottom: 4px;\"><div style=\"display: flex;\"><div style=\"flex-grow: 1; border-radius: 3px; text-align: left; position: relative; background: rgb(247, 246, 243); min-width: 0px; width: 100%;\"><div class=\"line-numbers notion-code-block\" style=\"display: flex; overflow-x: auto;\"><div contenteditable=\"false\" spellcheck=\"false\" autocorrect=\"off\" autocapitalize=\"off\" data-root=\"true\" style=\"flex-grow: 1; flex-shrink: 1; text-align: left; font-family: SFMono-Regular, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace; font-size: 85%; tab-size: 2; padding: 30px 16px 30px 20px; min-height: 1em; color: rgb(55, 53, 47); white-space: pre;\">rake generate   #生成静态网页\nrake deploy     #发布网页<span>\n</span></div></div><div style=\"position: absolute; top: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"></div><div style=\"position: absolute; bottom: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"><div role=\"button\" aria-disabled=\"true\" tabindex=\"-1\" style=\"user-select: none; transition: background 120ms ease-in 0s; display: inline-flex; align-items: center; white-space: nowrap; height: 20px; border-radius: 3px; font-size: 12px; line-height: 1.2; padding-left: 5px; padding-right: 5px; color: rgba(55, 53, 47, 0.6); margin-right: 5px;\">Plain Text<svg viewBox=\"0 0 30 30\" class=\"chevronDown\" style=\"width: 10px; height: 100%; display: block; fill: rgba(55, 53, 47, 0.3); flex-shrink: 0; backface-visibility: hidden; margin-left: 4px;\"><polygon points=\"15,17.4 4.8,7 2,9.8 15,23 28,9.8 25.2,7 \"></polygon></svg></div></div></div></div></div><div data-block-id=\"e9a92152-8f9e-4c8c-9af1-21b2ba2a94e3\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">或者也可以生成静态网页后，在本机进行预览</div></div></div></div><div data-block-id=\"6ba8173c-2c05-44bd-a71c-2a443f2579a8\" class=\"notion-selectable notion-code-block\" style=\"width: 100%; max-width: 608px; margin-top: 4px; margin-bottom: 4px;\"><div style=\"display: flex;\"><div style=\"flex-grow: 1; border-radius: 3px; text-align: left; position: relative; background: rgb(247, 246, 243); min-width: 0px; width: 100%;\"><div class=\"line-numbers notion-code-block\" style=\"display: flex; overflow-x: auto;\"><div contenteditable=\"false\" spellcheck=\"false\" autocorrect=\"off\" autocapitalize=\"off\" data-root=\"true\" style=\"flex-grow: 1; flex-shrink: 1; text-align: left; font-family: SFMono-Regular, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace; font-size: 85%; tab-size: 2; padding: 30px 16px 30px 20px; min-height: 1em; color: rgb(55, 53, 47); white-space: pre;\">rake preview<span>\n</span></div></div><div style=\"position: absolute; top: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"></div><div style=\"position: absolute; bottom: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"><div role=\"button\" aria-disabled=\"true\" tabindex=\"-1\" style=\"user-select: none; transition: background 120ms ease-in 0s; display: inline-flex; align-items: center; white-space: nowrap; height: 20px; border-radius: 3px; font-size: 12px; line-height: 1.2; padding-left: 5px; padding-right: 5px; color: rgba(55, 53, 47, 0.6); margin-right: 5px;\">Plain Text<svg viewBox=\"0 0 30 30\" class=\"chevronDown\" style=\"width: 10px; height: 100%; display: block; fill: rgba(55, 53, 47, 0.3); flex-shrink: 0; backface-visibility: hidden; margin-left: 4px;\"><polygon points=\"15,17.4 4.8,7 2,9.8 15,23 28,9.8 25.2,7 \"></polygon></svg></div></div></div></div></div><div data-block-id=\"f77e19cf-6d76-4f61-aaf5-c4af248f8df9\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">然后可以通过<span style=\"font-family:&quot;SFMono-Regular&quot;, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace;line-height:normal;background:rgba(135,131,120,0.15);color:#EB5757;border-radius:3px;font-size:85%;padding:0.2em 0.4em\" data-token-index=\"1\">http://localhost:4000</span>访问，状态满意即可发布网页，以上几步同样适用于更改网页布局、样式等，重新发布网页。 ## _config.yml 这是你的博客根目录下下的一个文件，通过编写它，可以设置网站基本信息，设置边栏等：</div></div></div></div><div data-block-id=\"2b220965-905e-4789-a2b6-692b99ae4712\" class=\"notion-selectable notion-code-block\" style=\"width: 100%; max-width: 608px; margin-top: 4px; margin-bottom: 4px;\"><div style=\"display: flex;\"><div style=\"flex-grow: 1; border-radius: 3px; text-align: left; position: relative; background: rgb(247, 246, 243); min-width: 0px; width: 100%;\"><div class=\"line-numbers notion-code-block\" style=\"display: flex; overflow-x: auto;\"><div contenteditable=\"false\" spellcheck=\"false\" autocorrect=\"off\" autocapitalize=\"off\" data-root=\"true\" style=\"flex-grow: 1; flex-shrink: 1; text-align: left; font-family: SFMono-Regular, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace; font-size: 85%; tab-size: 2; padding: 30px 16px 30px 20px; min-height: 1em; color: rgb(55, 53, 47); white-space: pre;\">url: http://812lcl.github.io        #网站地址\ntitle: 812lcl的博客                #网站名\nsubtitle: 不要好高骛远，却又原地踏步；只想不做，太辜负青春了     #网站副标题\nauthor: 812lcl                      #作者名\nlunr_search: false                  #lunr站内搜索，需要安装，麻烦\nsimple_search: http://google.com/search     #默认搜索引擎\ndescription:                        #网站描述\n...\ndefault_asides: [custom/asides/tag_cloud.html, asides/recent_posts.html, custom/asides/popular_posts.html...]\n#边栏需要在这里添加路径<span>\n</span></div></div><div style=\"position: absolute; top: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"></div><div style=\"position: absolute; bottom: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"><div role=\"button\" aria-disabled=\"true\" tabindex=\"-1\" style=\"user-select: none; transition: background 120ms ease-in 0s; display: inline-flex; align-items: center; white-space: nowrap; height: 20px; border-radius: 3px; font-size: 12px; line-height: 1.2; padding-left: 5px; padding-right: 5px; color: rgba(55, 53, 47, 0.6); margin-right: 5px;\">Plain Text<svg viewBox=\"0 0 30 30\" class=\"chevronDown\" style=\"width: 10px; height: 100%; display: block; fill: rgba(55, 53, 47, 0.3); flex-shrink: 0; backface-visibility: hidden; margin-left: 4px;\"><polygon points=\"15,17.4 4.8,7 2,9.8 15,23 28,9.8 25.2,7 \"></polygon></svg></div></div></div></div></div><div data-block-id=\"dcaed8c0-275f-4dfb-914a-ad8cdbee626c\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">这个文件是很重要的配置文件，配置博客需要经常修改此文件。 ## 目录结构 之所以要介绍目录结构，是为了更清晰的了解各个文件是做什么用的，修改网站样式添加侧栏等等需要修改那些文件。以免按着教程一个一个设置完成，在脑子中却一团糟不记得修改了什么，万一出现了错误就不好了。</div></div></div></div><div data-block-id=\"f7b15bdb-7893-4a3f-b4d0-5fa41ebe9346\" class=\"notion-selectable notion-code-block\" style=\"width: 100%; max-width: 608px; margin-top: 4px; margin-bottom: 4px;\"><div style=\"display: flex;\"><div style=\"flex-grow: 1; border-radius: 3px; text-align: left; position: relative; background: rgb(247, 246, 243); min-width: 0px; width: 100%;\"><div class=\"line-numbers notion-code-block\" style=\"display: flex; overflow-x: auto;\"><div contenteditable=\"false\" spellcheck=\"false\" autocorrect=\"off\" autocapitalize=\"off\" data-root=\"true\" style=\"flex-grow: 1; flex-shrink: 1; text-align: left; font-family: SFMono-Regular, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace; font-size: 85%; tab-size: 2; padding: 30px 16px 30px 20px; min-height: 1em; color: rgb(55, 53, 47); white-space: pre;\">├─ config.rb  #指定额外的compass插件\n├─ config.ru  \n├─ Rakefile   #rake的配置文件,类似于makefile\n├─ Gemfile    #bundle要下载需要的gem依赖关系的指定文件\n├─ Gemfile.lock  #这些gem依赖的对应关系,比如A的x本依赖于B的y版本\n├─ _config.yml   #站点的配置文件\n├─ public/      #在静态编译完成后的目录,网站只需要这个目录下的文件树\n├─ _deploy/     #deploy时候生成的缓存文件夹,和public目录一样\n├─ sass/    #css文件的源文件,过程中会compass成css\n├─ plugins/     #放置自带以及第三方插件的目录,ruby程序\n│  └── xxx.rb\n└─ source/  #站点的源文件目录,public目录就是根据这个目录下数据生成的\n   └─ _includes/\n      └─ custom/    #自定义的模板目录,被相应上级html include\n         └─ asides/     #边栏模板自定义模板目录\n      └─ asides/        #边栏模板目录\n      └─ post/          #文章页面相应模板目录\n   └─ _layouts/         #默认网站html相关文件,最底层\n   └─ _posts/       #新增以及从其它程序迁移过来的数据都存在这里\n   └─ stylesheets/  #css文件目录\n   └─ javascripts/      #js文件目录\n   └─ images/       #图片目录<span>\n</span></div></div><div style=\"position: absolute; top: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"></div><div style=\"position: absolute; bottom: 0px; right: 0px; color: rgba(55, 53, 47, 0.6); display: flex; align-items: center; justify-content: flex-end; height: 30px;\"><div role=\"button\" aria-disabled=\"true\" tabindex=\"-1\" style=\"user-select: none; transition: background 120ms ease-in 0s; display: inline-flex; align-items: center; white-space: nowrap; height: 20px; border-radius: 3px; font-size: 12px; line-height: 1.2; padding-left: 5px; padding-right: 5px; color: rgba(55, 53, 47, 0.6); margin-right: 5px;\">Plain Text<svg viewBox=\"0 0 30 30\" class=\"chevronDown\" style=\"width: 10px; height: 100%; display: block; fill: rgba(55, 53, 47, 0.3); flex-shrink: 0; backface-visibility: hidden; margin-left: 4px;\"><polygon points=\"15,17.4 4.8,7 2,9.8 15,23 28,9.8 25.2,7 \"></polygon></svg></div></div></div></div></div><div data-block-id=\"ef2999fd-a0cd-4f2c-af21-651750e313f0\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">其中需要添加第三方插件时，将插件xxx.rb放入plugins文件夹中。最主要的文件夹是source文件夹，因为修改网页都是在这个文件夹中进行。自己添加的边栏的HTML文件都放置于<span style=\"font-family:&quot;SFMono-Regular&quot;, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace;line-height:normal;background:rgba(135,131,120,0.15);color:#EB5757;border-radius:3px;font-size:85%;padding:0.2em 0.4em\" data-token-index=\"1\">source/_includes/custom/asides</span>中，然后再_config.yml中的default_asides:中添加对应的路径，即可在网页上显示出边栏。修改<span style=\"font-family:&quot;SFMono-Regular&quot;, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace;line-height:normal;background:rgba(135,131,120,0.15);color:#EB5757;border-radius:3px;font-size:85%;padding:0.2em 0.4em\" data-token-index=\"3\">source/_includes/</span>中的其他HTML文件，如header.html等，则可以修改标题栏、导航栏、尾栏等等。</div></div></div></div><div data-block-id=\"dd2be22d-05b5-4d01-bc0b-7c433792b2bd\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\"><span style=\"font-family:&quot;SFMono-Regular&quot;, Consolas, &quot;Liberation Mono&quot;, Menlo, Courier, monospace;line-height:normal;background:rgba(135,131,120,0.15);color:#EB5757;border-radius:3px;font-size:85%;padding:0.2em 0.4em\" data-token-index=\"0\">source/_layouts</span>中则是网站的布局的一些HTML文件，可以修改文件布局等等。三个文件夹目录是非常重要并且常修改的。source中images中则放置网站相关的一些图片，javascripts文件家中放置一些模块需要调用的javascript脚本，_post中则是你的每篇博客。</div></div></div></div><div data-block-id=\"111afc44-363e-4df7-8410-7bd194b6f917\" class=\"notion-selectable notion-divider-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div class=\"notion-cursor-default\" style=\"display: flex; align-items: center; justify-content: center; pointer-events: auto; width: 100%; height: 13px; flex: 0 0 auto; color: rgb(228, 227, 226);\"><div style=\"width: 100%; height: 1px; visibility: visible; border-bottom: 1px solid rgba(55, 53, 47, 0.09);\"></div></div></div><div data-block-id=\"c19318d3-2247-4a95-ae6b-d0295a323cb0\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">以上就是Octopress博客搭建的一个简单过程和目录结构，之后会详细介绍我的博客中各个模块建立的过程及出现的问题，敬请关注。</div></div></div></div><div data-block-id=\"dbd4f424-d36e-4e85-96de-44f0ca9835c6\" class=\"notion-selectable notion-text-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"color: inherit; fill: inherit;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\" \" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding: 3px 2px;\">参考文章：</div></div></div></div><div data-block-id=\"d8bf3913-ac74-4d19-bd7c-3476ba0eba30\" class=\"notion-selectable notion-bulleted_list-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"display: flex; align-items: flex-start; width: 100%; padding-left: 2px; color: inherit; fill: inherit;\"><div style=\"margin-right: 4px; width: 24px; display: flex; align-items: center; justify-content: center; flex-grow: 0; flex-shrink: 0; min-height: calc((1.5em + 3px) + 3px); padding-right: 2px;\"><div style=\"width: 6px; height: 6px; border-radius: 6px; background: currentcolor; margin-top: 0.1em;\"></div></div><div style=\"flex: 1 1 0px; min-width: 1px; display: flex; flex-direction: column;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\"List\" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding-top: 3px; padding-bottom: 3px; text-align: left;\"><a href=\"http://easypi.github.io/blog/2013/01/05/using-octopress-to-setup-blog-on-github/\" style=\"text-decoration:underline;color:inherit;cursor:pointer;word-wrap:break-word\" target=\"_blank\" rel=\"noopener noreferrer\" data-token-index=\"0\">利用Octopress在github Pages上搭建个人博客</a></div></div></div></div></div><div data-block-id=\"558851a0-a8d7-4ddd-a88a-eaa550633731\" class=\"notion-selectable notion-bulleted_list-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 1px;\"><div style=\"display: flex; align-items: flex-start; width: 100%; padding-left: 2px; color: inherit; fill: inherit;\"><div style=\"margin-right: 4px; width: 24px; display: flex; align-items: center; justify-content: center; flex-grow: 0; flex-shrink: 0; min-height: calc((1.5em + 3px) + 3px); padding-right: 2px;\"><div style=\"width: 6px; height: 6px; border-radius: 6px; background: currentcolor; margin-top: 0.1em;\"></div></div><div style=\"flex: 1 1 0px; min-width: 1px; display: flex; flex-direction: column;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\"List\" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding-top: 3px; padding-bottom: 3px; text-align: left;\"><a href=\"http://www.dongwm.com/archives/qian-yi-octpressyi-ji-zi-ding-yi/\" style=\"text-decoration:underline;color:inherit;cursor:pointer;word-wrap:break-word\" target=\"_blank\" rel=\"noopener noreferrer\" data-token-index=\"0\">迁移octpress,Rakefile修改以及豆瓣推荐,豆瓣收藏秀,新浪微博分享按钮等实现</a></div></div></div></div></div><div data-block-id=\"b5bff96d-978e-4303-8eb1-0b013f6ab9d5\" class=\"notion-selectable notion-bulleted_list-block\" style=\"width: 100%; max-width: 608px; margin-top: 1px; margin-bottom: 0px;\"><div style=\"display: flex; align-items: flex-start; width: 100%; padding-left: 2px; color: inherit; fill: inherit;\"><div style=\"margin-right: 4px; width: 24px; display: flex; align-items: center; justify-content: center; flex-grow: 0; flex-shrink: 0; min-height: calc((1.5em + 3px) + 3px); padding-right: 2px;\"><div style=\"width: 6px; height: 6px; border-radius: 6px; background: currentcolor; margin-top: 0.1em;\"></div></div><div style=\"flex: 1 1 0px; min-width: 1px; display: flex; flex-direction: column;\"><div style=\"display: flex;\"><div contenteditable=\"false\" spellcheck=\"true\" placeholder=\"List\" data-root=\"true\" style=\"max-width: 100%; width: 100%; white-space: pre-wrap; word-break: break-word; caret-color: rgb(55, 53, 47); padding-top: 3px; padding-bottom: 3px; text-align: left;\"><a href=\"http://www.csdn123.com/html/blogs/20130531/17852.htm\" style=\"text-decoration:underline;color:inherit;cursor:pointer;word-wrap:break-word\" target=\"_blank\" rel=\"noopener noreferrer\" data-token-index=\"0\">Octopress博客设置</a></div></div></div></div></div>","slug":"11bcf166f7244997adeee93b5ea0a764","keywords":["博客"]}},"pageContext":{"isCreatedByStatefulCreatePages":false,"slug":"11bcf166f7244997adeee93b5ea0a764"}}}