current position：Home>【github pages】: build a github pages under windows, update the blog in real time
【github pages】: build a github pages under windows, update the blog in real time
I made it once before, lost it, and tried it again.
- Install git: https://git-scm.com/download/win
- Install node: https://nodejs.org/en/
- Install cnpm:
npm install -g cnpm --registry==https://registry.npm.taobao.org
- Install hexo:
cnpm install -g hexo-cli
- Generate .ssh key:
ssh-keygen -t rsa -C "your github login email"
- Copy the public password to github: Copy the contents of
github homepage, enter personal settings -> SSHand GPG keys -> New SSH key
- Configure user and email:
git config --global user.name "your Github username"and
git config --global user.email "[email protected]"
- Create warehouse, CrazyMilk.github.io;
- Create two branches: master and hexo;
- Set hexo as the default branch (because we only need to manually manage the Hexo website files on this branch);
- Use git clone [email protected]:CrazyMilk/CrazyMilk.github.io.git to copy the warehouse;
- In the local CrazyMilk.github.io folder, execute npm install hexo, hexo init, npm install and npm install hexo-deployer-git sequentially through Git bash (at this time - the current branch should be displayed as hexo);
- Modify the deploy parameter in _config.yml, the branch should be master;
- Execute git add ., git commit -m “…”, git push origin hexo in sequence to submit website-related files;
- Execute hexo generate -d to generate the website and deploy it to GitHub.
In this way, the CrazyMilk.github.io warehouse on GitHub has two branches, a hexo branch is used to store the original files of the website, and a master branch is used to store the generated static web pages.Perfect ( •̀ ω •́ )y!
Typora is a lightweight and compact Markdown editor that supports instant rendering technology, which is the most significant difference from other Markdown editors.Instant rendering allows you to write Markdown as smoothly as writing a Word document, unlike other editors that have a formula bar and a display bar.
Simple and beautiful
1. In the
D:\hexo directory, by entering the command:
hexo new "article title" will be in the
/source folderGenerate the
.md file of the corresponding article, and then you can open this file through
Typora to write the article and save it
2. After you finish writing the article, enter the following commands to generate the article:
hexo clean: Delete the public folder, i.e. delete old blog posts
hexo g: Generate a public folder, that is, generate a new blog post related html file
hexo s: local view
hexo d: Push blog to master on github
3. In addition, the following command is required to push the deployment resources of this update to hexo
git add .
git commit -m "update"
git push -u hexo hexo:hexo
When only a few images are used in the Hexo project, the images can be placed in the source/images folder and accessed through markdown syntax.
![You can write a description about the picture](/images/image.jpg)
Images can be accessed both within the homepage content and within the body of the article.
author[Jack_Kuo],Please bring the original link to reprint, thank you.
The sidebar is recommended
- What are the key indicators to measure the service quality of small edge cloud?
- What is the development trend of edge cloud technology?
- Why is flexible delivery capability particularly important for cloud platforms?
- What are the technical characteristics of a small edge cloud?
- Based on the requirements of edge business scenarios, which features of the miniaturized edge cloud will affect customer access experience?
- What are the main needs of users for the edge side?
- Android App development used in network communication okhttp download and upload pictures, documents and actual combat, more detailed implementation (user registration information upload source attached)
- Install mysql under Linux
- Install lrzsz under Linux
- My brother teaches you to use CSS and JS to realize the once-popular WeChat plane game
guess what you like
LeetCode daily question (517. Super Washing Machines)
Install JDK under Linux
[Power system] CJAYA algorithm optimizes SDM parameters of photovoltaic model with matlab code
[AI] introduction to gradient descent algorithm (theory)
Redis Deep Adventure: Core Principles and Application Practice
[Classification-SVDD] Multi-class classification algorithm based on support vector data description (SVDD) with matlab code
Detailed explanation of Linux top command
SpringBoot Scenario Development Generalist Growth Manual
Detailed explanation of Linux rpm command
Apricot pear rain cloud IQI v10.0.3.1299 X Windows a key installation
- The configuration in the idea starts the web project through tomcat
- Optimal way to position wireless sensor nodes based on particle swarm optimization algorithm to mitigate coverage holes due to any energy depleted nodes Attached Matlab code
- Solving single-objective optimization problems (DDCS) based on dynamic control cuckoo algorithm with matlab code
- Solving simple scheduling problems based on leapfrog algorithm with matlab code
- Multi-objective cuckoo (MOCS) optimization algorithm with Matlab code
- Hot spots丨"Chinese elements" appear in the World Cup
- [Mysql] mysql lock waits for Lock wait timeout exceeded; try restarting transaction
- [SpringBoot] The SpringBoot @Value annotation cannot introduce the correct solution to the value in the configuration file
- [JAVA] Good code style in Java
- [JAVA] Two ways to read configuration files: ResourceBundle and Properties
- [JAVA] springboot multi-environment packaging
- Springboot interceptor injection failure leads to cross-domain
- Gateway encryption and decryption occasionally HTTP method names must be tokensConnection prematurely closed BEFORE response problem
- Install QT5 on ubuntu18.04
- [JAVA] logback log
- Let’s briefly summarize the daily tasks of a MySQL DBA in a day;
- [JAVA] Quartz timing tasks, automatic expiration, automatic shutdown, etc., integrate Springboot
- [JAVA] Maven profiles control multi-environment data source log packaging
- [JAVA] idea mac Jar package build method and Maven method
- 【JAVA】JWT token verification code
- How to completely uninstall idea on Mac (can be reinstalled and cracked)
- [JAVA] Use Hikari connection pool in springBoot
- [LINUX] About database, nginx, zookeeper, kafka, Jar package, tomcat startup method
- [Springboot] SpringBoot cannot read static files after printing the Jar package, showing that the file does not exist
- 【JAVA】idea hot deployment, background automatically update code spring, springboot
- Voice Home invites you to participate in WAIC 2022 World Artificial Intelligence Conference
- SVM algorithm (2)
- MySQL database: 6. Overview and syntax of constraints
- Ensemble Learning Algorithm
- Naive Bayes Algorithm (1)
- Mobile Development - Responsive
- Summary of Docker commands
- m Matlab simulation of wireless image transmission based on QPSK modulation and demodulation, including modules such as spread spectrum despread equalization
- Common memory leaks in Android - [problem analysis + solution]
- C++ Chinese Weekly Issue 88
- C++ Chinese Weekly Issue 89
- m Based on OFDM system, compare SC algorithm, Minn algorithm, PARK algorithm synchronization performance matlab simulation analysis
- How to distinguish and define DQL DML DDL and DCL in SQL
- Custom persistence layer framework MyORMFramework (1) - JDBC analysis and solutions
- What is the order in which SQL statements are executed?