登录linux vps.
cd ~
git clone https://github.com/theacodes/blog.thea.codes /usr/local/blog.thea.codes
cd /usr/local/blog.thea.codes
pip3 install -r requirements.txt
python3 build.py
root@racknerd-626f077:/usr/local/blog.thea.codes# python3 build.py
root@racknerd-626f077:/usr/local/blog.thea.codes# ls
build.py highlighting.py noxfile.py requirements.txt srcs templates
docs drafts LICENSE __pycache__ serve.py static witchhazel.py
root@racknerd-626f077:/usr/local/blog.thea.codes#
在当前目录下,生成了docs目录,它里面有index.html,可见 /usr/local/blog.thea.codes/docs就是静态网站的根目录。
新建源帖:
cd srcs
mkdir happy-festival
cd happy-festival
nano index.md
cat index.md
显示:
---
title: 快乐的节日
date: 2024-11-04
legacy_url: yes
description: 这是一篇文章
---
此处写正文或html codes.
cd ../..
python3 build.py
演示网站:
http://btc.briten.top/
项目地址:https://github.com/theacodes/blog.thea.codes
No comments:
Post a Comment