Skip to content

Conversation

@18202781743
Copy link
Contributor

@18202781743 18202781743 commented Jan 5, 2026

  1. Added installation of override configuration files in debian/dde-
    shell.install
  2. Updated CMakeLists.txt to install DTK preference override
    configuration
  3. Created new override file shell/overrides/
    org.deepin.dtk.preference.json
  4. The override file defines themeType configuration with proper
    metadata including Chinese translations

Log: Added DTK preference override configuration for theme type settings

Influence:

  1. Verify that the override configuration file is properly installed
    to /usr/share/dsg/configs/overrides/org.deepin.dde.shell/
  2. Test that theme type configuration is available through DTK
    configuration system
  3. Check that the themeType setting can be read and written correctly
  4. Verify Chinese translations for configuration name and description
  5. Ensure the configuration has proper permissions (readwrite) and
    visibility (public)
  6. Test that the override doesn't break existing configuration loading

fix: 添加DTK偏好设置覆盖配置

  1. 在debian/dde-shell.install中添加覆盖配置文件的安装
  2. 更新CMakeLists.txt以安装DTK偏好设置覆盖配置
  3. 创建新的覆盖文件shell/overrides/org.deepin.dtk.preference.json
  4. 覆盖文件定义了themeType配置,包含完整元数据和中文翻译

Log: 添加了主题类型设置的DTK偏好设置覆盖配置

Influence:

  1. 验证覆盖配置文件是否正确安装到/usr/share/dsg/configs/overrides/
    org.deepin.dde.shell/
  2. 测试主题类型配置是否可通过DTK配置系统访问
  3. 检查themeType设置能否正确读写
  4. 验证配置名称和描述的中文翻译
  5. 确保配置具有正确的权限(读写)和可见性(公开)
  6. 测试覆盖配置不会破坏现有的配置加载

PMS: BUG-345091

Summary by Sourcery

Add DTK configuration override for dde-shell theme preferences and ensure it is installed with the shell package.

New Features:

  • Introduce a DTK preference override configuration defining the themeType setting for dde-shell.

Enhancements:

  • Install the new DTK preference override file via CMake and Debian packaging so it is available at runtime.

1. Added installation of override configuration files in debian/dde-
shell.install
2. Updated CMakeLists.txt to install DTK preference override
configuration
3. Created new override file shell/overrides/
org.deepin.dtk.preference.json
4. The override file defines themeType configuration with proper
metadata including Chinese translations

Log: Added DTK preference override configuration for theme type settings

Influence:
1. Verify that the override configuration file is properly installed
to /usr/share/dsg/configs/overrides/org.deepin.dde.shell/
2. Test that theme type configuration is available through DTK
configuration system
3. Check that the themeType setting can be read and written correctly
4. Verify Chinese translations for configuration name and description
5. Ensure the configuration has proper permissions (readwrite) and
visibility (public)
6. Test that the override doesn't break existing configuration loading

fix: 添加DTK偏好设置覆盖配置

1. 在debian/dde-shell.install中添加覆盖配置文件的安装
2. 更新CMakeLists.txt以安装DTK偏好设置覆盖配置
3. 创建新的覆盖文件shell/overrides/org.deepin.dtk.preference.json
4. 覆盖文件定义了themeType配置,包含完整元数据和中文翻译

Log: 添加了主题类型设置的DTK偏好设置覆盖配置

Influence:
1. 验证覆盖配置文件是否正确安装到/usr/share/dsg/configs/overrides/
org.deepin.dde.shell/
2. 测试主题类型配置是否可通过DTK配置系统访问
3. 检查themeType设置能否正确读写
4. 验证配置名称和描述的中文翻译
5. 确保配置具有正确的权限(读写)和可见性(公开)
6. 测试覆盖配置不会破坏现有的配置加载

PMS: BUG-345091
@sourcery-ai
Copy link

sourcery-ai bot commented Jan 5, 2026

Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Adds a DTK configuration override for the dde-shell themeType preference and wires it into both the CMake install and Debian packaging so the override JSON is installed and picked up by the DTK configuration system.

Sequence diagram for DTK themeType configuration override loading

sequenceDiagram
    participant DdeShell
    participant DtkConfigSystem
    participant DefaultConfig
    participant OverrideConfigFile

    DdeShell->>DtkConfigSystem: loadThemeType()
    DtkConfigSystem->>DefaultConfig: read(org.deepin.dde.shell.json)
    DefaultConfig-->>DtkConfigSystem: themeType default metadata
    DtkConfigSystem->>OverrideConfigFile: read(org.deepin.dtk.preference.json)
    OverrideConfigFile-->>DtkConfigSystem: themeType override metadata
    DtkConfigSystem->>DtkConfigSystem: merge default and override
    DtkConfigSystem-->>DdeShell: effective themeType config (public, readwrite)

    DdeShell->>DtkConfigSystem: setThemeType(value)
    DtkConfigSystem-->>DdeShell: persist themeType value
Loading

File-Level Changes

Change Details Files
Wire DTK configuration override into the build/install system for dde-shell.
  • Extend CMake configuration to register a DTK config override file for org.deepin.dde.shell using dtk_add_config_override_files with the org.deepin.dtk.preference meta name.
  • Ensure the override JSON is installed alongside existing DTK config metadata so it is discovered at runtime.
shell/CMakeLists.txt
Package the DTK preference override JSON for Debian installs.
  • Add the override JSON path to the Debian .install file so it is installed into /usr/share/dsg/configs/overrides/org.deepin.dde.shell/ in Debian packages.
debian/dde-shell.install
Introduce DTK preference override definition for themeType.
  • Create overrides/org.deepin.dtk.preference.json that defines the themeType configuration override, including metadata, permissions/visibility settings, and Chinese translations for name and description.
  • Structure the override file so that reads/writes to themeType go through DTK’s configuration system without breaking existing config loading.
shell/overrides/org.deepin.dtk.preference.json

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

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

Hey - I've reviewed your changes and they look great!


Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@deepin-ci-robot
Copy link

deepin pr auto review

我来帮你审查这个 git diff。这个变更主要涉及 DDE Shell 的配置文件安装和主题类型配置。让我从多个角度进行分析:

  1. 语法逻辑:
  • JSON 格式正确,符合 DSG 配置文件规范
  • CMakeLists.txt 中的命令语法正确
  • debian/dde-shell.install 文件格式正确
  1. 代码质量:
  • 配置文件结构清晰,包含了必要的字段
  • 提供了中英文双语说明,提高了国际化支持
  • 配置项命名规范,使用驼峰命名法
  1. 性能影响:
  • 仅添加了配置文件,不会对运行时性能产生直接影响
  • 配置文件较小,不会显著增加安装包大小
  1. 安全性:
  • 配置权限设置为 "readwrite",这是合理的
  • 可见性设置为 "public",允许其他应用访问

改进建议:

  1. 配置文件方面:
  • 建议在 "flags" 字段中明确指定配置的持久化策略
  • 可以考虑添加配置值的验证规则,确保只能设置 0、1、2 这三个有效值
  1. 安装路径方面:
  • 建议在 debian/dde-shell.install 中添加注释说明新增配置文件的用途
  • 可以考虑将配置文件版本号单独定义,便于后续维护
  1. 文档方面:
  • 建议添加 README 文档说明新配置项的使用方法
  • 可以在提交信息中更详细地说明这个变更的目的和影响
  1. 版本控制:
  • 建议在 JSON 文件中添加 "lastModified" 字段,便于追踪配置更新
  • 可以考虑为配置变更添加版本号,便于后续升级管理
  1. 测试建议:
  • 建议添加单元测试验证配置项的读写功能
  • 建议添加集成测试验证主题切换功能

这些改进建议可以帮助提高代码的可维护性、可靠性和用户体验。你觉得这些建议怎么样?需要我详细解释某个方面吗?

@deepin-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: 18202781743, BLumia, mhduiy

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

Details 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

@18202781743 18202781743 merged commit 4d94be0 into linuxdeepin:master Jan 5, 2026
9 of 11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants