Directory Structure#
.
├── .deploy_git
├── node_modules
├── public
├── scaffolds
│ ├── draft.md
│ ├── page.md
│ └── post.md
├── source
│ └── _posts
│ └── hello-world.md
├── themes
├── .gitignore
├── _config.yml
├── db.json
├── package.json
└── package-lock.json
.deploy_git#
Automatically created after deploying to GitHub with the command hexo d
. The structure of this directory is basically the same as the public
directory (the inconsistency occurs when it is regenerated but not published, in which case the content in public
is newer than that in .deploy_git
).
node_modules#
Stores the installed Hexo extensions, which are the corresponding node dependency modules.
public#
When the hexo g
command is executed, the Hexo program compiles the source
and theme
directories, and the generated static webpage content is stored in the public
directory.
The content of the generated public
folder can be directly deployed as a static website.
When the hexo d
command is executed, the content of the public
directory is copied to the .deploy_git
directory.
scaffolds#
scaffolds
means "scaffold". When you create a new article (hexo new 'title'
), Hexo builds it based on the files in this directory.
source#
The place to store user resources.
_posts#
The place to store blog articles. The markdown
files, HTML files, org files, etc. in this directory will be parsed and placed in the public
folder for publication on the website.
Other files/folders starting with _#
They will be ignored. Therefore, you can create a _drafts
directory in the source
directory to store unfinished drafts, which will not be published on the website.
Other files/folders not starting with _#
They will be copied to the public
directory and uploaded to the website.
- You can create an
img
directory to store images referenced in the blog, etc. - To add a new page (e.g.,
about
), execute the commandhexo new page PageName
, and a subdirectoryPageName
will be automatically created in thesource
directory. - The
favicon.ico
is referenced in the theme configuration file to set the page icon of the website.
themes#
The directory for website themes. The landscape
theme is installed by default, and you can install new themes to the themes
directory or create your own.
_config.yml#
The global configuration file where many website information is configured, such as website name, subtitle, description, author, language, theme, deployment, and other parameters.
db.json#
An automatically generated JSON file that can be used to manage and search for blog files. It can be ignored.
package.json#
The parameters of the Hexo framework and all the plugins it depends on.