使用Hexo搭建博客网站(二)

设置主题

我们在官方主题中选择一个自己喜欢的主题
来到GitHub,将它git clone到当前项目的themes文件夹中

设置_config.yml

找到

# Extensions
## Plugins: https://hexo.io/plugins/
## Themes: https://hexo.io/themes/
theme: landscape

只需将这个landscape名字改为你新设置的主题名字就行

新建文章post

npx hexo new "first post"

新建了first-post文章

新建菜单页面page

新建一个 about 关于菜单

npx hexo new page about

设置图片

{% img [class names] /path/to/image [width] [height] '"title text" "alt text"' %}
#举例
{% img 花儿 /images/spring/daisy.jpg 100 100 '"雏菊" "多年生草本植物"' %}
posted @ 2025-06-13 14:20  Ritchie^._.^  阅读(275)  评论(0)    收藏  举报