Git Product home page Git Product logo

hexo-blog-repo's Introduction

博客备份

  1. 安装 npm
    sudo apt-get install npm
  2. 安装 hexo
    sudo npm install -g hexo
  3. 创建博客
    cd blog # 需要进入到 hexo 项目路径下才能使用命令
    hexo init # 初始化项目(仅首次需要)
    hexo new post <title> # 创建post
  4. 部署博客
    hexo g # 产生文件
    hexo s # 本机访问 http://localhost:4000/
    hexo d # 部署(需要先hexo g产生文件)
  5. 配置文件
    1. _config.yml 内部有部署的服务器和一些网站内容设置
    2. source/_posts 博文
  6. 出现 node_modules 相关的问题
    rm -rf node_modules
    npm install --force
  7. 插入图片 要在 source 下创建一个 images 文件夹,然后 ![IMG](/images/xx.png) 的方式引用,hexo 部署后的根目录就是 source,所以 / 代表 source 目录,我们要用绝对路径,因为非首页的情况下同样文章的所在路径不同。另外必须在 source 目录下,原因同上,source 外不会被算入。

hexo-blog-repo's People

Contributors

sunhuiquan avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.