美文网首页
Hexo 博客个性化配置--以freemind为例

Hexo 博客个性化配置--以freemind为例

作者: Raspberry | 来源:发表于2016-01-08 04:34 被阅读1012次

    安装 & 基本信息

    git clone https://github.com/wzpan/hexo-theme-freemind.git themes/freemind```
    - 找到`Hexo/_config.yml, line 66`theme栏把landscape 换成freemind
    - 接下来修改剩下的必要信息[参见作者介绍]()
    <!--more-->
    
    ## 修改上顶栏
    
    ![修改前](https://img.haomeiwen.com/i135897/c61644bd8f644619.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)
    
    ![点开categories](https://img.haomeiwen.com/i135897/c61a1958472dee31.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)
    
    所以我们先要确定页面。
    > **千万注意 _config.yml 去里面所有的项目冒号后面要加一个空格如果有内容的话**
    
    下面的错做需要在
    `Hexo/theme/freemind/_config`中修改信息
    例如:
    ![这是默认的配置](https://img.haomeiwen.com/i135897/c2c2e84f948d1b3f.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)
    而尝试了点一下,发现后面的几项都还没有工作
    ,这是应为相应的页面放在`Hexo/source/`目录的文件夹里。比如归档已经有了,而其他的还没有。我们希望建立tags页面,这使用
    ``` bash
    hexo new page "tags"```
    然后修改`Hexo/source/rags/index.html`文件
    

    title: Categories
    layout: categories
    ---```
    如果不需要,吧对应的栏目注释掉即可

    Paste_Image.png 注释掉后的效果
    Paste_Image.png
    • 添加豆瓣读书插件
      Paste_Image.png
      教程
      一、安装插件:
      npm install hexo-generator-douban --save
      二、添加配置:
      
      
    plugins:
    - hexo-generator-douban   
    
    douban:
      user: xxx```
    
    ![Paste_Image.png](https://img.haomeiwen.com/i135897/5dcd968628ea0add.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)
    
    ![hexo s 后效果图](https://img.haomeiwen.com/i135897/6261a3ba10c81f50.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)
    
    ### 添加wiki 页面
    ---
    ![wiki在_config.yml 中的修改样式](https://img.haomeiwen.com/i135897/dc080c27d3cb5f7f.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)
    - [这一片](http://www.voidking.com/2015/05/31/deve-hexo-theme-optimize/),我照着做了一遍
    - 其中添加头像章节看的这里[制作icon](http://www.bitbug.net/) (教程)[http://www.jianshu.com/p/73779eacb494]  
    然后把生成的32*32 的favicon.png 放到 `hexo/theme/freemind/source`目录下面即可;404 页面也放在这个文件夹下面
    - 修改页面语言,这里指的是比如按钮里面的文字是中文还是英文之类的
    `hexo/_config.yml`line10 写上default 则为英语,如果协商zh-CN 则变中文
    - 新加了几个分栏
      这个主题需要的格式比较奇怪的,多一个图标项
    - 每一页的显示文章数目 [参考]http://www.isetsuna.com/hexo/theme-plugin/
    - 部署前先装 deploy plug 否则不成功
    ```Bash
       npm install hexo-deployer-git --save```
    
    - 添加tag增强栏目!
    https://github.com/wzpan/hexo-tag-bootstrap
    [tag加强的问题](http://wzpan.github.io/hexo-theme-freemind/2014/03/16/tag-plugins-cn/)
    ``` bash
    npm install hexo-tag-bootstrap --save
    
    npm install hexo-tag-bootstrap --save```
    
    
    - [豆瓣标签](http://lqs.link/2015/08/17/Hexo%203.x%20%E6%8A%93%E5%8F%96%E8%B1%86%E7%93%A3%E8%AF%BB%E4%B9%A6/)
        一、安装插件:   
        ```npm install hexo-generator-douban --save```
        二、添加配置:   
        ```vim blog/_config.yml (not blog/themes/yillia/_config.yml), add following lines:
    
    

    plugins:

    • hexo-generator-douban

    douban:
    user: xxx```

       url: atom.xml 
       icon: "fa fa-rss"```
    - 添加disqus 模块
    默认集成了,在`hexo\_config.yml`中添加如下就行代码即可
    
    ![Paste_Image.png](https://img.haomeiwen.com/i135897/976191ca729b9ecb.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/1240)
    
    http://fionat.github.io/blog/2013/10/23/sitemap/
    ```npm install hexo-generator-feed --save```
    ```npm install hexo-generator-sitemap --save```

    相关文章

      网友评论

          本文标题:Hexo 博客个性化配置--以freemind为例

          本文链接:https://www.haomeiwen.com/subject/uobfkttx.html