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

feat: add an API to list uninstalled themes #2586

Merged
merged 3 commits into from
Oct 18, 2022

Conversation

guqing
Copy link
Member

@guqing guqing commented Oct 17, 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?

支持扫描主题目录下未安装的主题

@f2c-ci-robot f2c-ci-robot bot added release-note Denotes a PR that will be considered when it comes time to generate release notes. kind/feature Categorizes issue or PR as related to a new feature. labels Oct 17, 2022
@f2c-ci-robot f2c-ci-robot bot added this to the 2.0 milestone Oct 17, 2022
@f2c-ci-robot f2c-ci-robot bot added area/core Issues or PRs related to the Halo Core kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API labels Oct 17, 2022
Copy link
Member

@ruibaby ruibaby left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@f2c-ci-robot f2c-ci-robot bot added the lgtm Indicates that a PR is ready to be merged. label Oct 17, 2022
@f2c-ci-robot f2c-ci-robot bot removed the lgtm Indicates that a PR is ready to be merged. label Oct 18, 2022
@guqing guqing requested a review from JohnNiang October 18, 2022 04:07
Copy link
Member

@JohnNiang JohnNiang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/approve

@f2c-ci-robot
Copy link

f2c-ci-robot bot commented Oct 18, 2022

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: JohnNiang

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@f2c-ci-robot f2c-ci-robot bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 18, 2022
Copy link
Member

@ruibaby ruibaby left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@f2c-ci-robot f2c-ci-robot bot added the lgtm Indicates that a PR is ready to be merged. label Oct 18, 2022
@f2c-ci-robot f2c-ci-robot bot merged commit 58e98f0 into halo-dev:main Oct 18, 2022
f2c-ci-robot bot pushed a commit to halo-dev/console that referenced this pull request 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 pull request 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
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/core Issues or PRs related to the Halo Core kind/api-change Categorizes issue or PR as related to adding, removing, or otherwise changing an API kind/feature Categorizes issue or PR as related to a new feature. lgtm Indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

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