Hexo git to different computer
Hexo git to different computer
create a clean local hexo blog directory
install hexo first !
1 | npm install hexo-cli -g |
Initialize hexo folder
1 | hexo init FOLDER_NAME |
Change “_config.yml”
1 | url: https://username.github.io/ |
Generate
1 | under hexo folder |
Pull the Blog page repo & copy the local hexo files to a different working branch
1 | git clone git@github.com:Pyrad/Pyrad.github.io.git |
Create a new branch for hexo folder
1 | Create a new branch: hexo |
Clean the branch
1 | git rm -rf . |
Copy all files inside the previous hexo folder here
1 | cp -rf /path/to/hexolocal/.github . |
Regenerate the hexo file modules
1 | cnpm install |
Try hexo
1 | hexo -v |
Hexo git to different computer
https://pyrad.github.io/2021/07/19/hexo-git-on-diff-computers/
You need to set
install_url
to use ShareThis. Please set it in _config.yml
.