Skip to content

cherry-studio@1.7.2: Switch to portable version#16045

Merged
z-Fng merged 11 commits intoScoopInstaller:masterfrom
GeorgeDong32:optimize-cherry-manifest
Dec 11, 2025
Merged

cherry-studio@1.7.2: Switch to portable version#16045
z-Fng merged 11 commits intoScoopInstaller:masterfrom
GeorgeDong32:optimize-cherry-manifest

Conversation

@GeorgeDong32
Copy link
Copy Markdown
Contributor

@GeorgeDong32 GeorgeDong32 commented Aug 23, 2025

  • Switch Cherry Studio manifest to portable version
  • Add notes and depends
  • Optimize persist
  • Use conventional PR title: <manifest-name[@version]|chore>: <general summary of the pull request>
  • I have read the Contributing Guide

Summary by CodeRabbit

  • New Features

    • Switched installers to portable executables for simpler deployment and updates.
    • Added top-level data persistence and automatic migration to preserve user settings.
    • Renamed the desktop shortcut to match the portable executable name.
    • Added a suggestion to install the VC Redistributable when needed.
  • Chores

    • Updated package metadata and auto-update URLs/hashes for portable builds.

✏️ Tip: You can customize this high-level summary in your review settings.

@github-actions
Copy link
Copy Markdown
Contributor

All changes look good.

Wait for review from human collaborators.

cherry-studio

  • Description
  • License
  • Hashes
  • Checkver
  • Autoupdate

@GeorgeDong32
Copy link
Copy Markdown
Contributor Author

/verify

@github-actions
Copy link
Copy Markdown
Contributor

All changes look good.

Wait for review from human collaborators.

cherry-studio

  • Description
  • License
  • Hashes
  • Checkver
  • Autoupdate

@GeorgeDong32
Copy link
Copy Markdown
Contributor Author

@Lutra-Fs Sorry for the previous PR ( #16005 ) which caused some issues due to my mistake. I've opened a new PR now, please review it.

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Dec 4, 2025

Walkthrough

Switched Cherry Studio from installer packages to portable executables for both architectures, added top-level pre_install script, added a top-level persist field, added a vcredist suggestion, renamed the shortcut, updated hashes and autoupdate URLs, and removed per-architecture pre_install and the legacy post_install block.

Changes

Cohort / File(s) Summary
Cherry Studio package manifest
bucket/cherry-studio.json
Replaced 64bit and arm64 installer URLs with portable cherry-studio.exe URLs and updated hashes; updated autoupdate URLs to portable paths; added top-level pre_install PowerShell script to copy APPDATA user data into the persist directory when needed; removed per-architecture pre_install blocks and the legacy post_install relocation logic; added top-level persist = "data"; added suggest object with vcredist; renamed shortcut from "Cherry Studio.exe" to "cherry-studio.exe".

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10–15 minutes

  • Check portable download URLs and verify SHA hashes match binaries.
  • Review the new top-level pre_install PowerShell script for edge cases (existing destination data, permissions, path correctness).
  • Validate removal of per-arch pre_install and post_install does not leave legacy cases unhandled.
  • Confirm the persist field and renamed shortcut match installer/packaging expectations and autoupdate behavior.

Poem

🐰 I hopped through manifests, light on my paws,
Replaced old installers with portable laws,
I tucked data safe in a folder called "data",
Suggested vcredist, renamed a shortcut — tata!
A tiny rabbit cheers these tidy new claws.

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely summarizes the main change: switching Cherry Studio to a portable version, which is the primary modification across the manifest.
Description check ✅ Passed The description includes a bullet-point summary of changes and confirms completion of the required checklist items (conventional PR title and Contributing Guide acknowledgment).
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@z-Fng z-Fng changed the title cherry-studio@1.5.6: Switch Cherry Studio manifest to portable version cherry-studio@1.7.1: Switch to portable version Dec 4, 2025
Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7a0aa04 and 0b13068.

📒 Files selected for processing (1)
  • bucket/cherry-studio.json (1 hunks)
🧰 Additional context used
🧠 Learnings (2)
📚 Learning: 2025-10-14T11:15:55.229Z
Learnt from: SorYoshino
Repo: ScoopInstaller/Extras PR: 16333
File: bucket/potplayer.json:55-64
Timestamp: 2025-10-14T11:15:55.229Z
Learning: In PotPlayer manifests (bucket/potplayer.json), the Model and Engine folders are created at runtime (not included in the installer), so they should only be in the persist list and not in post_install scripts that handle .original directories.

Applied to files:

  • bucket/cherry-studio.json
📚 Learning: 2025-10-19T13:58:23.389Z
Learnt from: o-l-a-v
Repo: ScoopInstaller/Extras PR: 16378
File: bucket/compactgui.json:20-22
Timestamp: 2025-10-19T13:58:23.389Z
Learning: In the ScoopInstaller/Extras repository, the CompactGUI manifest removed hash verification from the autoupdate block because the hash verification mechanism (scraping SHA-256 from release page HTML) is no longer available in newer CompactGUI releases. GitHub asset digests exist in beta releases but not in v3.8.0, and Scoop doesn't have built-in support for extracting from GitHub API asset digests.

Applied to files:

  • bucket/cherry-studio.json
🔇 Additional comments (6)
bucket/cherry-studio.json (6)

6-14: Clear and informative metadata additions.

The notes array effectively communicates the data persistence change and provides migration context. The vcredist2022 dependency is appropriately marked as a suggestion for users who may need the Visual C++ Runtime.


25-43: Post-install migration logic is sound, with one potential edge case to consider.

The data migration script properly handles two scenarios:

  1. When $persist_dir\data exists but is empty (lines 27-35)
  2. When $persist_dir\data does not exist yet (lines 36-42)

However, verify that Scoop creates the persist directory before post_install runs. If it does, the else branch (lines 36-42) may be unreachable during fresh installations. If Scoop does not pre-create persist directories, the ensure call at line 39 is necessary and correct.


47-47: Shortcut filename correctly matches URL rename fragment.

The shortcut references cherry-studio.exe (line 47), which aligns with the #/cherry-studio.exe rename fragment in the download URLs (lines 17, 21). This ensures the portable executable is correctly renamed and accessible.


51-51: Persist field correctly declared for data directory.

Setting persist to "data" ensures that user data in the $persist_dir\data directory is preserved across Scoop updates, which integrates properly with the post_install migration logic.


58-58: Autoupdate URLs correctly target portable executable paths.

The autoupdate block uses the portable executable path template with version substitution, maintaining consistency with the current download URLs and ensuring future updates also use portable executables.

Also applies to: 61-61


25-43: Remove ensure and info function calls—these are not available in Scoop's post_install environment.

The post_install script at lines 33, 39, and 41 uses ensure and info functions that are not part of Scoop's standard helper functions. According to Scoop's official documentation, the available core functions during post_install are: Invoke-HookScript, Invoke-Installer, env_add_path, env_set, Add-Path, Set-EnvVar, Publish-EnvVar, Invoke-ScoopDownload, Invoke-Extraction, persist_data, link_current, and create_shims. The script will fail at runtime when attempting to call ensure or info. Consider replacing these with appropriate PowerShell alternatives (e.g., Write-Host for logging) or removing them if they are informational only. Note: $persist_dir is correctly available during post_install execution.

⛔ Skipped due to learnings
Learnt from: o-l-a-v
Repo: ScoopInstaller/Extras PR: 16328
File: bucket/winutil.json:0-0
Timestamp: 2025-10-13T09:37:06.093Z
Learning: When reviewing code in Scoop manifests, always verify the actual file content if the diff appears incomplete or unusual, as diff context can be truncated or displayed incorrectly. The pattern `[string[]](...).ForEach{...}` is commonly used in post_uninstall scripts across the Extras repository.
Learnt from: SorYoshino
Repo: ScoopInstaller/Extras PR: 16333
File: bucket/potplayer.json:55-64
Timestamp: 2025-10-14T11:24:17.524Z
Learning: In PotPlayer manifests (bucket/potplayer.json), the Capture and Playlist folders are created at runtime (after running the application), not included in the installer, so they should only be in the persist list and not in post_install scripts.
Learnt from: SorYoshino
Repo: ScoopInstaller/Extras PR: 16333
File: bucket/potplayer.json:55-64
Timestamp: 2025-10-14T11:15:55.229Z
Learning: In PotPlayer manifests (bucket/potplayer.json), the Model and Engine folders are created at runtime (not included in the installer), so they should only be in the persist list and not in post_install scripts that handle .original directories.

@z-Fng z-Fng changed the title cherry-studio@1.7.1: Switch to portable version cherry-studio@1.7.2: Switch to portable version Dec 11, 2025
Copy link
Copy Markdown

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 0b13068 and b39963a.

📒 Files selected for processing (1)
  • bucket/cherry-studio.json (1 hunks)
🧰 Additional context used
🧠 Learnings (4)
📚 Learning: 2025-10-19T13:58:23.389Z
Learnt from: o-l-a-v
Repo: ScoopInstaller/Extras PR: 16378
File: bucket/compactgui.json:20-22
Timestamp: 2025-10-19T13:58:23.389Z
Learning: In the ScoopInstaller/Extras repository, the CompactGUI manifest removed hash verification from the autoupdate block because the hash verification mechanism (scraping SHA-256 from release page HTML) is no longer available in newer CompactGUI releases. GitHub asset digests exist in beta releases but not in v3.8.0, and Scoop doesn't have built-in support for extracting from GitHub API asset digests.

Applied to files:

  • bucket/cherry-studio.json
📚 Learning: 2025-10-14T11:15:55.229Z
Learnt from: SorYoshino
Repo: ScoopInstaller/Extras PR: 16333
File: bucket/potplayer.json:55-64
Timestamp: 2025-10-14T11:15:55.229Z
Learning: In PotPlayer manifests (bucket/potplayer.json), the Model and Engine folders are created at runtime (not included in the installer), so they should only be in the persist list and not in post_install scripts that handle .original directories.

Applied to files:

  • bucket/cherry-studio.json
📚 Learning: 2025-11-29T22:02:34.868Z
Learnt from: Ra2-IFV
Repo: ScoopInstaller/Extras PR: 16672
File: bucket/chromium-clang.json:12-12
Timestamp: 2025-11-29T22:02:34.868Z
Learning: In the chromium-clang.json manifest (bucket/chromium-clang.json), the extract_dir value "chrome-win32" is a fixed name determined by the upstream Chromium_Clang archive structure and should not be changed, even though the manifest targets 64-bit architecture.

Applied to files:

  • bucket/cherry-studio.json
📚 Learning: 2025-09-05T09:41:52.653Z
Learnt from: Gitoffthelawn
Repo: ScoopInstaller/Extras PR: 16106
File: bucket/czkawka-gui.json:25-25
Timestamp: 2025-09-05T09:41:52.653Z
Learning: For czkawka-gui manifests in Scoop Extras, the correct upstream filename pattern for Windows GUI builds in recent versions uses "gtk46" (without underscore), not "gtk_46" (with underscore). The autoupdate URL should use "windows_czkawka_gui_gtk46.zip" format. This was confirmed by a working 10.0.0 update with valid hash.

Applied to files:

  • bucket/cherry-studio.json
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: WindowsPowerShell
🔇 Additional comments (2)
bucket/cherry-studio.json (2)

29-29: Confirm portable archive structure supports exe extraction and rename.

The shortcut references "cherry-studio.exe" which is extracted via the URL pattern #/cherry-studio.exe. This assumes the portable archive contains a single exe or one primary exe that can be isolated. Verify that the Cherry Studio v1.7.2 portable downloads have the expected structure (e.g., a single Cherry-Studio-1.7.2-x64-portable.exe that Scoop can extract as cherry-studio.exe).

The persist field "data" is appropriately scoped for a portable app with localized user data storage.

Also applies to: 33-33


40-40: Autoupdate URLs follow the portable exe pattern consistently.

The autoupdate block correctly uses the portable exe URL template for both architectures. No issues detected; the pattern is consistent with the initial URLs. Ensure upstream maintains the Cherry-Studio-$version-{x64|arm64}-portable.exe naming convention in future releases.

Also applies to: 43-43

@z-Fng
Copy link
Copy Markdown
Member

z-Fng commented Dec 11, 2025

/verify

@github-actions
Copy link
Copy Markdown
Contributor

All changes look good.

Wait for review from human collaborators.

cherry-studio

  • Lint
  • Description
  • License
  • Hashes
  • Checkver
  • Autoupdate

Check the full log for details.

Copy link
Copy Markdown
Member

@z-Fng z-Fng left a comment

Choose a reason for hiding this comment

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

Thanks for your contribution! If there are any other changes, feel free to open an issue or submit a PR anytime.

@z-Fng z-Fng merged commit 9bfa993 into ScoopInstaller:master Dec 11, 2025
3 checks passed
@pilgrimlyieu
Copy link
Copy Markdown

According to the issue mentioned below, the portable version cannot pin the shortcut on taskbar or start automatically at boot:

@coderabbitai coderabbitai bot mentioned this pull request Mar 15, 2026
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants