|
|
6 gadi atpakaļ | |
|---|---|---|
| .. | ||
| lib | 6 gadi atpakaļ | |
| .editorconfig | 6 gadi atpakaļ | |
| LICENSE | 6 gadi atpakaļ | |
| README.md | 6 gadi atpakaļ | |
| index.js | 6 gadi atpakaļ | |
| package.json | 6 gadi atpakaļ | |
Automatically add front-matter categories to Hexo article according to the article file directory.
Directory is means relative form article file path to Hexo source _posts folder.
$ cd <your-hexo-site>
$ npm install --save hexo-directory-category
You can configure this plugin in site _config.yml.
auto_dir_categorize:
enable: true # options:true, false; default is true
force: false # options:true, false; default is false
# file: ./_posts/Linux/Vim/note/test.md
...
categories: [CS, Usage]
tags: [...]
# After hexo generate, it will nothing Conversion. categories: [CS, Usage]
# file: ./_posts/Linux/Vim/note/test.md
...
# categories: [...]
tags: [...]
# After hexo generate, it will convert to categories: [Linux, Vim, note]
# file: ./_posts/Linux/Vim/note/test.md
...
categories: [CS, Usage]
tags: [...]
# After hexo generate, it also will convert to categories: [Linux, Vim, note]