Skip to content

Make scripts/diff-filter.pl portable to macOS#8839

Merged
tautschnig merged 1 commit intodiffblue:developfrom
tautschnig:diff-filter-portability
Mar 4, 2026
Merged

Make scripts/diff-filter.pl portable to macOS#8839
tautschnig merged 1 commit intodiffblue:developfrom
tautschnig:diff-filter-portability

Conversation

@tautschnig
Copy link
Copy Markdown
Collaborator

This change impact analysis helper used sed in ways not portable to macOS.

  • Each commit message has a non-empty body, explaining why the change was made.
  • n/a Methods or procedures I have added are documented, following the guidelines provided in CODING_STANDARD.md.
  • n/a The feature or user visible behaviour I have added or modified has been documented in the User Guide in doc/cprover-manual/
  • Regression or unit tests are included, or existing tests cover the modified code (in this case I have detailed which ones those are in the commit message).
  • n/a My commit message includes data points confirming performance improvements (if claimed).
  • My PR is restricted to a single feature or bugfix.
  • n/a White-space or formatting changes outside the feature-related changed lines are in commits of their own.

Copilot AI review requested due to automatic review settings February 23, 2026 12:56
Copy link
Copy Markdown

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 pull request fixes a macOS portability issue in the diff-filter.pl script by modifying the sed -i command to work on both GNU and BSD (macOS) sed implementations.

Changes:

  • Modified sed -i to sed -i.bak with explicit backup extension for macOS compatibility
  • Added cleanup step to remove the temporary backup file after editing

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/goto-diff/scripts/diff-filter.pl Outdated
@codecov
Copy link
Copy Markdown

codecov Bot commented Feb 23, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 80.00%. Comparing base (7ff43f7) to head (5554b2c).

Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #8839   +/-   ##
========================================
  Coverage    80.00%   80.00%           
========================================
  Files         1700     1700           
  Lines       188271   188271           
  Branches        73       73           
========================================
+ Hits        150632   150633    +1     
+ Misses       37639    37638    -1     

☔ 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.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@tautschnig tautschnig self-assigned this Feb 24, 2026
Use Perl file I/O instead of shelling out to sed for line-prefix
editing. This avoids both the macOS sed -i portability issue and
potential shell injection via unquoted file paths in backtick commands.

Co-authored-by: Kiro <kiro-agent@users.noreply.github.com>
@tautschnig tautschnig force-pushed the diff-filter-portability branch from ef60854 to 5554b2c Compare March 4, 2026 13:42
@tautschnig tautschnig requested a review from a team as a code owner March 4, 2026 14:08
@tautschnig tautschnig force-pushed the diff-filter-portability branch from 63b72b4 to 5554b2c Compare March 4, 2026 14:34
@tautschnig tautschnig merged commit 5059d48 into diffblue:develop Mar 4, 2026
74 of 79 checks passed
@tautschnig tautschnig deleted the diff-filter-portability branch March 4, 2026 19:15
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.

3 participants