generated from halo-dev/plugin-starter
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
51 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,54 @@ | ||
# plugin-sitemap | ||
|
||
Halo 2.0 的站点 Sitemap 链接生成插件(WIP) | ||
Halo 2.0 的站点 Sitemap 链接生成插件。 | ||
|
||
安装插件之后会提供一个 `http://your-host/sitemap.xml` 的链接作为站点的 Sitemap。 | ||
## 开发环境 | ||
|
||
```bash | ||
git clone [email protected]:halo-sigs/plugin-sitemap.git | ||
|
||
# 或者当你 fork 之后 | ||
|
||
git clone [email protected]:{your_github_id}/plugin-sitemap.git | ||
``` | ||
|
||
```bash | ||
cd path/to/plugin-sitemap | ||
``` | ||
|
||
```bash | ||
# macOS / Linux | ||
./gradlew pnpmInstall | ||
|
||
# Windows | ||
./gradlew.bat pnpmInstall | ||
``` | ||
|
||
```bash | ||
# macOS / Linux | ||
./gradlew build | ||
|
||
# Windows | ||
./gradlew.bat build | ||
``` | ||
|
||
修改 Halo 配置文件: | ||
|
||
```yaml | ||
halo: | ||
plugin: | ||
runtime-mode: development | ||
classes-directories: | ||
- "build/classes" | ||
- "build/resources" | ||
lib-directories: | ||
- "libs" | ||
fixedPluginPath: | ||
- "/path/to/plugin-sitemap" | ||
``` | ||
## 使用方式 | ||
1. 在 [Releases](https://github.com/halo-sigs/plugin-sitemap/releases) 下载最新的 JAR 文件。 | ||
2. 在 Halo 后台的插件管理上传 JAR 文件进行安装。 | ||
3. 启动插件之后,即可通过 `https://your-host/sitemap.xml` 来访问站点地图。 |