HUGO搭建
本项目为 hugo博客搭建过程中的一些问题,还在学习中,望见谅…
博客的创建
- hugo new site myblog
 - hugo –theme=dimension –baseUrl=“https://lxiuaanng.github.io/" –buildDrafts
 - cd p….
 - git init
 - git add .
 - git commit -m “第一次提交”
 - git remote add origin https://github.com/lxiuaunng/lxiuaunng.github.io.git
 - git push -u origin master
 - git remote -v /查看当前通道/
 - git remote set-url origin git@github.com:lxiuaanng/lxiuaanng.github.io.git /修改https通道为ssh/
 - git config –global –unset user.name
 - git config –global –unset user.email /删除全局用户名和邮箱/
 - git config user.name "”
 - git config user.email “" /单独配置用户名和邮箱/
 
问题1
-   [rejected]        master -> master (fetch first)
error: failed to push some refs to ‘https://github.com/lxiuaunng/lxiuaunng.github.io.git’
hint: Updates were rejected because the remote contains work that you do
hint: not have locally. This is usually caused by another repository pushing
hint: to the same ref. You may want to first integrate the remote changes
hint: (e.g., ‘git pull …’) before pushing again.
hint: See the ‘Note about fast-forwards’ in ‘git push –help’ for details. - git pull –rebase origin master
 - 或者git push -f origin master //强推,删除远仓所有文件,将自己的文件全推上去
 
git 配置
git config –global user.name ‘你的用户名’
git config –global user.email ‘你的邮箱’

