我的个人博客搭建成功啦!
这篇文章会给大家分享我是如何从0开始搭建我的个人独立博客的
接下来我们开始吧
准备工具首先我们需要到对应网站下载需要的工具下载nodejs 下载Git一直点确定就行,全部按它默认勾的
接下来测试是否安装成功管理员运行cmd,依次输入
123node -vnpm -v(这个是node附带的)git -v
下载Hexo
1npm install hexo-cli -g
搭建仓库成功下载好工具之后,开始搭建GitHub存储静态页面的仓库首先注册/登入Github点击Create a new repository进入新建仓库页面仓库名输入:
1用户名.github.io
勾选 Public
勾选 Add a README file
拉到下面点击create创建
生成SSH Keys进入任意文件夹,右键空白处然后点Git bash here,输入
1ssh-keygen -t rsa -C "邮件地址"
然后敲4次Enter⌨️
然后进入C:\Users\用户名,在里面进入.ssh文件
用记事本打开里面的id_rsa.pub,全选 ...
Welcome to Hexo! This is your very first post. Check documentation for more info. If you get any problems when using Hexo, you can find the answer in troubleshooting or you can ask me on GitHub.
Quick StartCreate a new post1$ hexo new "My New Post"
More info: Writing
Run server1$ hexo server
More info: Server
Generate static files1$ hexo generate
More info: Generating
Deploy to remote sites1$ hexo deploy
More info: Deployment