Skip to content

Conversation

@SorYoshino
Copy link
Contributor

@SorYoshino SorYoshino commented Jan 11, 2026

Summary

Refactors the opera manifest to add ARM64 support, optimizes the installation process, and enhances the version detection logic for better reliability.

Related issues or pull requests

Changes

  • Add arm64 architecture support for Windows.
  • Improve installer script:
    • Replace implicit extraction with Expand-7zipArchive for better control.
  • Enhance checkver logic:
    • Improve the scraper to use Invoke-WebRequest with -ErrorAction Stop for better error handling.
    • Update the regex to Opera_([\d.]+)_Setup for more precise version matching.
    • Refine the iteration logic to target the Windows-specific setup path more accurately.

Testing

The test results are as follows:
┏[ D:\Software\Scoop\Local\apps\scoop\current\bin][ master ≡]
└─> .\checkver.ps1 -App opera -Dir 'D:\Temporary\Software\Microsoft\Windows Sandbox\Repositories\Scoop\Buckets\Extras\bucket' -f
opera: 126.0.5750.18 (scoop version is 126.0.5750.18)
Forcing autoupdate!
Autoupdating opera
DEBUG[1768170679] $substitutions (hashtable) -> D:\Software\Scoop\Local\apps\scoop\current\lib\autoupdate.ps1:221:5
DEBUG[1768170679] $substitutions.$matchTail                     .18
DEBUG[1768170679] $substitutions.$baseurl                       https://get.geo.opera.com/pub/opera/desktop/126.0.5750.18/win
DEBUG[1768170679] $substitutions.$urlNoExt                      https://get.geo.opera.com/pub/opera/desktop/126.0.5750.18/win/Opera_126.0.5750.18_Setup_arm64
DEBUG[1768170679] $substitutions.$cleanVersion                  1260575018
DEBUG[1768170679] $substitutions.$underscoreVersion             126_0_5750_18
DEBUG[1768170679] $substitutions.$matchHead                     126.0.5750
DEBUG[1768170679] $substitutions.$basename                      Opera_126.0.5750.18_Setup_arm64.exe
DEBUG[1768170679] $substitutions.$url                           https://get.geo.opera.com/pub/opera/desktop/126.0.5750.18/win/Opera_126.0.5750.18_Setup_arm64.exe
DEBUG[1768170679] $substitutions.$match1                        126.0.5750.18
DEBUG[1768170679] $substitutions.$minorVersion                  0
DEBUG[1768170679] $substitutions.$basenameNoExt                 Opera_126.0.5750.18_Setup_arm64
DEBUG[1768170679] $substitutions.$buildVersion                  18
DEBUG[1768170679] $substitutions.$majorVersion                  126
DEBUG[1768170679] $substitutions.$patchVersion                  5750
DEBUG[1768170679] $substitutions.$dashVersion                   126-0-5750-18
DEBUG[1768170679] $substitutions.$preReleaseVersion             126.0.5750.18
DEBUG[1768170679] $substitutions.$version                       126.0.5750.18
DEBUG[1768170679] $substitutions.$dotVersion                    126.0.5750.18
DEBUG[1768170679] $hashfile_url = https://get.geo.opera.com/pub/opera/desktop/126.0.5750.18/win/Opera_126.0.5750.18_Setup_arm64.exe.sha256sum -> D:\Software\Scoop\Local\apps\scoop\current\lib\autoupdate.ps1:224:5
Searching hash for Opera_126.0.5750.18_Setup_arm64.exe in https://get.geo.opera.com/pub/opera/desktop/126.0.5750.18/win/Opera_126.0.5750.18_Setup_arm64.exe.sha256sum
DEBUG[1768170680] $regex = ^\s*([a-fA-F0-9]+)\s*$ -> D:\Software\Scoop\Local\apps\scoop\current\lib\autoupdate.ps1:78:9
Found: a12a44911f5ad97ff12aa3349bb3cdc4acd972041363229f22b93fb41d181351 using Extract Mode
Writing updated opera manifest

┏[ D:\Software\Scoop\Local\apps\scoop\current\bin][ master ≡]
└─> scoop install Unofficial/opera --arch arm64
Installing 'opera' (126.0.5750.18) [arm64] from 'Unofficial' bucket
Loading Opera_126.0.5750.18_Setup_arm64.exe from cache.
Checking hash of Opera_126.0.5750.18_Setup_arm64.exe ... ok.
Running installer script...done.
Linking D:\Software\Scoop\Local\apps\opera\current => D:\Software\Scoop\Local\apps\opera\126.0.5750.18
Creating shortcut for Opera (opera.exe)
Persisting profile
'opera' (126.0.5750.18) was installed successfully!
  • 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

    • Added ARM64 architecture support, enabling Opera installations on ARM64-compatible systems with corresponding ARM64-specific installer files and updates
  • Bug Fixes

    • Corrected homepage URL configuration by removing extraneous trailing slashes from manifest values
    • Updated and consolidated installer and autoupdate URL handling to improve consistency, reliability, and version parsing
    • Enhanced installation script file processing operations with improved cleanup and destination path handling

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

@coderabbitai
Copy link

coderabbitai bot commented Jan 11, 2026

Walkthrough

The PR updates the Opera installer manifest in Scoop by adding arm64 architecture support, refactoring installer script logic for file handling and cleanup, restructuring version checking to use web-scraping with releases URLs, and updating autoupdate URLs accordingly.

Changes

Cohort / File(s) Summary
Opera manifest configuration
bucket/opera.json
Added arm64 architecture entry with Setup_arm64.exe URL and hash; refactored installer script to use 7-zip expansion with cleanup steps; restructured file movement destinations under $dir\$version\$Name; updated version checking logic to parse version paths with regex instead of version strings; reworked autoupdate URLs to remove trailing suffixes and add arm64 entry; minor variable renames and encoding adjustments

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

Suggested labels

review-needed

Suggested reviewers

  • z-Fng

Poem

🐰 A rabbit hops through Windows built for arms, (64, 32, and ARM64 charms!)
Seven zips expand with care, version checks dance through the air,
From Opera's stage to Scoop's embrace, manifests evolve with grace! 🎭✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and specifically describes the main changes: adding arm64 support and updating the installer script and version check logic.
Description check ✅ Passed The description provides a clear summary, links to related issues, details all changes, includes comprehensive testing results, and confirms adherence to PR conventions.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


📜 Recent review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 62c7244 and 242d6de.

📒 Files selected for processing (1)
  • bucket/opera.json
🧰 Additional context used
🧠 Learnings (3)
📓 Common learnings
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.
Learnt from: o-l-a-v
Repo: ScoopInstaller/Extras PR: 16349
File: bucket/fvim.json:45-49
Timestamp: 2025-10-16T15:59:21.258Z
Learning: In Scoop manifests, the `autoupdate.url` and `autoupdate.architecture.<arch>.url` fields must be valid URIs according to the JSON schema (defined with `"format": "uri"`). Variables like `$matchUrlx64` that contain only path segments must be combined with a base URL (e.g., `https://github.com/.../releases/download/`) to form a complete valid URI.
Learnt from: haussmann
Repo: ScoopInstaller/Extras PR: 16863
File: bucket/browseros.json:15-17
Timestamp: 2025-12-21T13:49:44.001Z
Learning: In Scoop manifests, when a URL uses a fragment like `#/dl.7z`, Scoop automatically extracts the archive after download. For nested archives (like BrowserOS), the downloaded installer may contain another archive (e.g., `chrome.7z`) that requires explicit extraction via the installer script using `Expand-7zipArchive`. The installer script should reference the inner archive name, not the outer `dl.7z`.
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.
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 uses "gtk46" (without underscore), not "gtk_46" (with underscore). The autoupdate URL should use "windows_czkawka_gui_gtk46.zip" format.
📚 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/opera.json
📚 Learning: 2025-10-16T15:59:21.258Z
Learnt from: o-l-a-v
Repo: ScoopInstaller/Extras PR: 16349
File: bucket/fvim.json:45-49
Timestamp: 2025-10-16T15:59:21.258Z
Learning: In Scoop manifests, the `autoupdate.url` and `autoupdate.architecture.<arch>.url` fields must be valid URIs according to the JSON schema (defined with `"format": "uri"`). Variables like `$matchUrlx64` that contain only path segments must be combined with a base URL (e.g., `https://github.com/.../releases/download/`) to form a complete valid URI.

Applied to files:

  • bucket/opera.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 (5)
bucket/opera.json (5)

3-4: LGTM!

Minor cleanup: description refined and trailing slash removed from homepage URL for consistency.


17-21: LGTM! ARM64 support added.

The new arm64 architecture entry follows the established URL and hash pattern consistently with the existing 64bit and 32bit entries.


23-36: LGTM! Installer script refactored for explicit extraction control.

Good improvements:

  • Using Expand-7zipArchive with -Removal provides explicit control over extraction and cleanup.
  • The *_list file cleanup step is a good addition.
  • Adding -Depth 5 to ConvertTo-Json ensures proper serialization of nested objects.

56-58: Verify: Regex excludes 32-bit-only releases.

The regex '(?<=Setup\w+)\.exe$' requires word characters after "Setup", which matches Setup_x64.exe and Setup_arm64.exe but not Setup.exe (the 32-bit installer).

If Opera releases a version with only a 32-bit installer, checkver will skip it and fall back to an older version.

If this is intentional to ensure arm64 availability before updating, the logic is fine. Otherwise, consider:

-    $installer_name = $download_page.Links | Where-Object { $_.href -match '(?<=Setup\\w+)\\.exe$' } |
+    $installer_name = $download_page.Links | Where-Object { $_.href -match 'Setup(_\\w+)?\\.exe$' } |

63-78: LGTM! Autoupdate section properly extended for ARM64.

The autoupdate URLs correctly follow the established pattern and include the new arm64 architecture. The hash URL pattern $url.sha256sum is consistently applied.


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.

@github-actions
Copy link
Contributor

All changes look good.

Wait for review from human collaborators.

opera

  • Lint
  • Description
  • License
  • Hashes
  • Checkver
  • Autoupdate
  • Autoupdate Hash Extraction

Check the full log for details.

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.

1 participant