Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Console 主题列表支持扫描工作目录未安装的主题 #2554

Closed
ruibaby opened this issue Oct 13, 2022 · 1 comment · Fixed by #2586 or halo-dev/console#648
Closed

Console 主题列表支持扫描工作目录未安装的主题 #2554

ruibaby opened this issue Oct 13, 2022 · 1 comment · Fixed by #2586 or halo-dev/console#648
Assignees
Labels
area/console Issues or PRs related to the Halo Console area/core Issues or PRs related to the Halo Core kind/feature Categorizes issue or PR as related to a new feature. priority/critical-urgent Highest priority. Must be actively worked on as someone's top priority right now.
Milestone

Comments

@ruibaby
Copy link
Member

ruibaby commented Oct 13, 2022

你当前使用的版本

2.0.0-alpha.2

描述一下此特性

由于目前主题需要将 theme.yaml 持久化到数据库才能识别。所以在开发环境创建新主题的时候不是特别方便初始化主题信息,所以期望提供接口支持扫描在工作目录(~/halo-next/themes)中未安装的主题,然后在 Console 端显示并提供安装的功能。

/kind feature
/milestone 2.0
/area core
/area console
/priority critical-urgent

附加信息

No response

@f2c-ci-robot f2c-ci-robot bot added this to the 2.0 milestone Oct 13, 2022
@f2c-ci-robot f2c-ci-robot bot added kind/feature Categorizes issue or PR as related to a new feature. area/core Issues or PRs related to the Halo Core area/console Issues or PRs related to the Halo Console priority/critical-urgent Highest priority. Must be actively worked on as someone's top priority right now. labels Oct 13, 2022
@guqing
Copy link
Member

guqing commented Oct 13, 2022

/assign

f2c-ci-robot bot pushed a commit that referenced this issue Oct 18, 2022
#### What type of PR is this?
/kind feature
/milestone 2.0
/area core
/kind api-change

#### What this PR does / why we need it:
新增 API 用于查询未安装的主题

#### Which issue(s) this PR fixes:

Fixes #2554

#### Special notes for your reviewer:
how to test it?
1. 安装几个主题
2. 直接解压几个主题到 work dir 的 themes 目录
3. 使用以下 endpoint 查询未安装的主题,期望获得所有未安装主题的 themes.yaml 信息
```
/apis/api.console.halo.run/v1alpha1/themes?uninstalled=true
```

/cc @halo-dev/sig-halo 
#### Does this PR introduce a user-facing change?

```release-note
支持扫描主题目录下未安装的主题
```
f2c-ci-robot bot pushed a commit to halo-dev/console that referenced this issue Oct 18, 2022
)

#### What type of PR is this?

/kind feature
/milestone 2.0

#### What this PR does / why we need it:

支持显示和安装**未安装**的主题,以方便主题开发的时候,创建主题资源。适配 halo-dev/halo#2586

#### Which issue(s) this PR fixes:

Fixes halo-dev/halo#2554

#### Screenshots:

<img width="1663" alt="image" src="https://user-images.githubusercontent.com/21301288/196148567-f43b1bf3-e745-4c1a-950d-65899c1ae73c.png">

#### Special notes for your reviewer:

/cc @halo-dev/sig-halo-console 

测试方式:

1. 需要 `pnpm install`
2. Halo 需要切换到 halo-dev/halo#2586 PR 的分支。
3. 在本地的 `~/halo-dev/themes` 创建新的主题,需要包含 `themes.yaml`,或者将现有的主题直接下载到 `~/halo-dev/themes`
4. 检查后台主题管理的主题列表中是否显示了未安装的主题,以及测试是否可以安装成功。

#### Does this PR introduce a user-facing change?

```release-note
支持显示和安装未安装的主题,以方便主题开发的时候,创建主题资源。
```
JohnNiang pushed a commit to JohnNiang/halo that referenced this issue Mar 2, 2023
…alo-dev/console#648)

#### What type of PR is this?

/kind feature
/milestone 2.0

#### What this PR does / why we need it:

支持显示和安装**未安装**的主题,以方便主题开发的时候,创建主题资源。适配 halo-dev#2586

#### Which issue(s) this PR fixes:

Fixes halo-dev#2554

#### Screenshots:

<img width="1663" alt="image" src="https://user-images.githubusercontent.com/21301288/196148567-f43b1bf3-e745-4c1a-950d-65899c1ae73c.png">

#### Special notes for your reviewer:

/cc @halo-dev/sig-halo-console 

测试方式:

1. 需要 `pnpm install`
2. Halo 需要切换到 halo-dev#2586 PR 的分支。
3. 在本地的 `~/halo-dev/themes` 创建新的主题,需要包含 `themes.yaml`,或者将现有的主题直接下载到 `~/halo-dev/themes`
4. 检查后台主题管理的主题列表中是否显示了未安装的主题,以及测试是否可以安装成功。

#### Does this PR introduce a user-facing change?

```release-note
支持显示和安装未安装的主题,以方便主题开发的时候,创建主题资源。
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/console Issues or PRs related to the Halo Console area/core Issues or PRs related to the Halo Core kind/feature Categorizes issue or PR as related to a new feature. priority/critical-urgent Highest priority. Must be actively worked on as someone's top priority right now.
Projects
None yet
2 participants