Skip to content

Bf fix snap 2#717

Merged
lidaobing merged 4 commits intomainfrom
bf_fix_snap_2
Feb 2, 2026
Merged

Bf fix snap 2#717
lidaobing merged 4 commits intomainfrom
bf_fix_snap_2

Conversation

@lidaobing
Copy link
Member

@lidaobing lidaobing commented Feb 2, 2026

Summary by Sourcery

Adjust snap packaging layout and installation prefix for iptux.

Enhancements:

  • Bind /usr/share/iptux in the snap layout to the snap’s usr/share directory to align paths.
  • Update Meson installation prefix to /usr and simplify snap part organization for the iptux build.

@lidaobing lidaobing requested a review from Copilot February 2, 2026 04:57
@sourcery-ai
Copy link

sourcery-ai bot commented Feb 2, 2026

Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

Adjusts the Snap build layout and Meson install prefix so files are installed directly under /usr inside the snap, using a layout bind for /usr/share/iptux instead of organizing under /snap/iptux/current/usr.

Flow diagram for Snap build and installation with new Meson prefix

flowchart TD
  A[Meson configuration
  prefix=/usr] --> B[Build iptux
  using meson plugin]
  B --> C[Install files into
  $SNAP/usr/...]
  C --> D[Snap layout
  bind /usr/share/iptux
  to $SNAP/usr/share/iptux]
  D --> E[At runtime, app
  accesses /usr/share/iptux
  inside sandbox]
  E --> F[Layout presents
  snap path as
  /usr/share/iptux
  to application]
Loading

File-Level Changes

Change Details Files
Switch Meson install prefix to /usr so built artifacts install directly into the snap’s /usr tree.
  • Update meson-parameters to use --prefix=/usr instead of a snap-specific path
snap/snapcraft.yaml
Remove post-build path reorganization in favor of a Snap layout bind for /usr/share/iptux.
  • Remove organize rule that remapped snap/iptux/current/usr to usr
  • Add layout section binding /usr/share/iptux in the runtime environment to $SNAP/usr/share/iptux
snap/snapcraft.yaml

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 left some high level feedback:

  • Since the Meson prefix is now /usr and the layout binds /usr/share/iptux, double-check any hardcoded /snap/iptux/current/usr paths in desktop files, hooks, or scripts and update them to match the new runtime layout.
  • If the application only needs specific resources under /usr/share/iptux (e.g., icons or data files), consider binding only those subdirectories in the layout instead of the entire path to minimize the surface of the layout override.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- Since the Meson prefix is now `/usr` and the layout binds `/usr/share/iptux`, double-check any hardcoded `/snap/iptux/current/usr` paths in desktop files, hooks, or scripts and update them to match the new runtime layout.
- If the application only needs specific resources under `/usr/share/iptux` (e.g., icons or data files), consider binding only those subdirectories in the layout instead of the entire path to minimize the surface of the layout override.

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.

@github-actions
Copy link

github-actions bot commented Feb 2, 2026

Test Results

69 tests  ±0   69 ✅ ±0   3s ⏱️ ±0s
32 suites ±0    0 💤 ±0 
 1 files   ±0    0 ❌ ±0 

Results for commit b9b056f. ± Comparison against base commit cd325cd.

@codecov
Copy link

codecov bot commented Feb 2, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 51.75%. Comparing base (cd325cd) to head (b9b056f).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #717   +/-   ##
=======================================
  Coverage   51.75%   51.75%           
=======================================
  Files          64       64           
  Lines        8704     8704           
=======================================
  Hits         4505     4505           
  Misses       4199     4199           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes snap packaging configuration by replacing a complex path workaround with the proper snap layout feature. The previous approach used a non-standard install prefix and the organize directive to restructure files, which has been replaced with a cleaner layout bind mount.

Changes:

  • Changed meson prefix from /snap/iptux/current/usr to the standard /usr
  • Removed the organize section that was working around path issues
  • Added a layout section to bind-mount /usr/share/iptux to the snap's data directory

@lidaobing lidaobing merged commit 04a6534 into main Feb 2, 2026
24 of 25 checks passed
@lidaobing lidaobing deleted the bf_fix_snap_2 branch February 2, 2026 05:00
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.

1 participant