feat(changelog): sync linglong.yaml version and enable workflow for app repos - #803
feat(changelog): sync linglong.yaml version and enable workflow for app repos#803mhduiy wants to merge 1 commit into
Conversation
1. update-changelog.yml: auto-detect linglong*.yaml and sync package.version when its base version matches the current changelog version, keeping the numeric suffix (e.g. 7.0.64.1 -> 7.0.65.1). Independent versions are skipped. 2. Add call-update-changelog entry to 37 app repos (branches verified against actual remote branches: master/develop/snipe/release/snipe/release/eagle). 3. Create configs for deepin-scanner and udisks2-qt6. Log: sync linglong version in changelog update workflow for app repos Influence: update-changelog workflow for app projects
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: mhduiy The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
Reviewer's GuideExtends the update-changelog workflow to detect and synchronize linglong YAML package versions with debian/changelog and wires this workflow into multiple linuxdeepin app repositories via new/updated repo config entries. Sequence diagram for syncing linglong.yaml in update-changelog workflowsequenceDiagram
actor Developer
participant AppRepo
participant GitHubActions
participant update_changelog_workflow as update-changelog.yml
participant sync_linglong as Sync_linglong_step
Developer->>AppRepo: Push changelog change
AppRepo->>GitHubActions: Trigger update-changelog.yml
GitHubActions->>update_changelog_workflow: Run workflow
update_changelog_workflow->>update_changelog_workflow: prepare step outputs version and current_version
update_changelog_workflow->>sync_linglong: Sync linglong.yaml version
alt linglong*.yaml present and version matches base
sync_linglong->>sync_linglong: Update linglong*.yaml versions
sync_linglong-->>update_changelog_workflow: files output includes debian/changelog and linglong*.yaml
else no matching linglong version
sync_linglong-->>update_changelog_workflow: files output debian/changelog only
end
update_changelog_workflow->>GitHubActions: Create pull request with add-paths = files
GitHubActions-->>Developer: PR with synced debian/changelog and linglong*.yaml
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
deepin pr auto review★ 总体评分:95分■ 【总体评价】
■ 【详细分析】
■ 【改进建议代码示例】 # 建议增加对 current_base 的非空校验
@@ -294,6 +294,8 @@
current_base = strip_epoch(current_version)
+ if not current_base:
+ raise ValueError("current_version is empty after stripping epoch")
targets = sorted(repo_root.glob("linglong*.yaml")) |
There was a problem hiding this comment.
Hey - I've left some high level feedback:
- In the
strip_epoch/ version bump logic, epochs are stripped for comparison but never reattached when constructingnew_val, so versions like1:5.6.23.1will lose their epoch; consider preserving and re-prepending the epoch when writing the updated version. - The upload-artifact step still hardcodes
linglong*.yamlrather than using${{ steps.sync_linglong.outputs.files }}, which may cause mismatches or failures if nolinglong*.yamlexists or filenames differ; aligning this with the dynamic file list would make the workflow more robust.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- In the `strip_epoch` / version bump logic, epochs are stripped for comparison but never reattached when constructing `new_val`, so versions like `1:5.6.23.1` will lose their epoch; consider preserving and re-prepending the epoch when writing the updated version.
- The upload-artifact step still hardcodes `linglong*.yaml` rather than using `${{ steps.sync_linglong.outputs.files }}`, which may cause mismatches or failures if no `linglong*.yaml` exists or filenames differ; aligning this with the dynamic file list would make the workflow more robust.Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
Summary
update-changelog.yml: auto-detect
linglong*.yamlin repo root. Ifpackage.version's base version matches the current changelog version, sync it with the new changelog version, keeping the numeric suffix (e.g.7.0.64.1→7.0.65.1). Projects with independent linglong versions are skipped automatically.App repos: add
call-update-changelog.ymlentries to 39 linuxdeepin app repos (38 appended + 2 new configs for deepin-scanner and udisks2-qt6). Branch lists were verified against actual remote branches (master/develop/snipe/release/snipe/release/eagle).Testing
Verified on peeweep-test/dtkcore-test:
5.6.23+ linglong5.6.23.1→ PR updates both to5.6.24/5.6.24.1✓5.6.23+ independent linglong5.6.3→ linglong skipped, changelog only ✓Log: sync linglong version in changelog update workflow for app repos
Influence: update-changelog workflow for app projects
Summary by Sourcery
Keep compatible linglong package versions aligned with changelog updates and expand workflow configuration across LinuxDeepin application repositories.
New Features:
Enhancements: