We welcome you to join the development of Hexo. 🤗
Development
We welcome you to join the development of Hexo. This document will help you through the process.
Before You Start
Please read Contributor Covenant Code of Conduct first.
Please follow the coding style:
- Follow Google JavaScript Style Guide.
- Use soft-tabs with a two space indent.
- Don’t put commas first.
Also, Hexo has its own ESLint config, so please make sure your contribution will make ESLint happy.
Workflow
- Fork hexojs/hexo.
- Clone the repository to your computer and install dependencies.
$ git clone https://github.com/<username>/hexo.git |
- Create a feature branch.
$ git checkout -b new_feature |
- Start hacking.
- Push the branch:
$ git push origin new_feature |
- Create a pull request and describe the change.
Notice
- Please don’t modify version number in
package.json
. - Your pull request will only get merged when tests passed. Don’t forget to run tests before submission.
$ npm test |
Updating official-plugins
Also, we welcome PR or issue to official-plugins. 🤗
Updating Documentation
The Hexo documentation is open source and you can find the source code on hexojs/site.
Workflow
- Fork hexojs/site
- Clone the repository to your computer and install dependencies.
$ npm install hexo-cli -g # If you don't have hexo-cli installed |
- Start editing the documentation. You can start the server for live previewing.
$ hexo server |
- Push the branch.
- Create a pull request and describe the change.
Translating
- Add a new language folder in
source
folder. (All lower case) - Copy Markdown and template files in
source
folder to the new language folder. - Add the new language to
source/_data/language.yml
. - Copy
en.yml
inthemes/navy/languages
and rename it to the language name (all lower case).
Reporting Issues
When you encounter some problems when using Hexo, you can find the solutions in Troubleshooting or ask me on GitHub or Google Group. If you can’t find the answer, please report it on GitHub.
- Represent the problem in debug mode.
- Follow the steps from the issue template to provide a debug message and version when submitting a new issue at GitHub.