用Hexo搭建个人博客
阅读原文时间:2023年07月11日阅读:2

博客地址: http://astraylinux.com/

We need npm(Node Package Manager) to install Hexo.

1
2
3
4
5
6
7
8
9
10
11

yum install npm
mkdir hexo
cd hexo
npm install hexo --save
npm install hexo-server --save
npm install hexo-deployer-git --save
#use hexo start
hexo init
npm install #I not run this command at first, Hexo has "Can not Get/" error
hexo g #generate
hexo s #server

If hexo work well, you can through http://youhost:4000 to
open it.

We should create a repository name like “astraylinux.github.io” (astraylinux is mine)

Then config the _config.yml

1
2
3
4

deploy:
type: git
repo: ssh://git@github.com/astraylinux/astraylinux.github.io
branch: master

run command

1
2

hexo g
hexo d #deploy

Now http://astraylinux.github.io working.

I found great themes:

1
2

https://github.com/litten/hexo-theme-yilia
https://github.com/iissnan/hexo-theme-next

1

git clone https://github.com/iissnan/hexo-theme-next themes/next

手机扫一扫

移动阅读更方便

阿里云服务器
腾讯云服务器
七牛云服务器

你可能感兴趣的文章