A few days ago I received the task to build hexo blog, where I set up the recording process.
1. First configure the local environment, the official website to download node official website to download
and follow the prompts to install, install to a different disk. Here I installed the "D: \ download \ New Folder "
to open the cmd
detection installation
1 node -v
2 npm -v
2. Open the directory just installed, create a folder node_global
andnode_cache
1 npm config set prefix "D:\download\New Folder\node_global"
2 npm config set cache "D:\download\New Folder\node_cache"
Configuration Environment Variables
new variables NODE_PATH
and Path
both values are "D: \ downloads \ New Folder \ node_global"
4. Test global variable
opening cmd
installation hexo -cli
, then the following command
1 npm install hexo-cli -g
2 hexo
If you want to detect hexo created, you can enter the code below
and then you can enter http: // localhost: 4000 / viewed
Reference article from hexo deployment