Skip to content

Add context option for filter diffs - #421

Merged
mbrt merged 1 commit into
mbrt:masterfrom
kpengboy:diff-context
Jan 19, 2025
Merged

Add context option for filter diffs#421
mbrt merged 1 commit into
mbrt:masterfrom
kpengboy:diff-context

Conversation

@kpengboy

Copy link
Copy Markdown
Contributor

This adds a --context option to the diff subcommand and a --diff-context option to the apply and edit commands. The option allows the number of lines of diff context to be customized, which is helpful for verifying the correctness of changes to more complex filters.

@codecov

codecovBot commented Jan 18, 2025

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 31.81818% with 15 lines in your changes missing coverage. Please review.

Project coverage is 54.52%. Comparing base (c566f95) to head (7dd5035).
Report is 3 commits behind head on master.

Files with missing linesPatch %Lines
cmd/gmailctl/cmd/apply_cmd.go0.00%5 Missing ⚠️
cmd/gmailctl/cmd/diff_cmd.go0.00%5 Missing ⚠️
cmd/gmailctl/cmd/edit_cmd.go0.00%5 Missing ⚠️
Additional details and impacted files
@@ Coverage Diff @@## master #421 +/- ##
==========================================
- Coverage 54.63% 54.52% -0.12% 
==========================================
Files 53 53 Lines 4448 4457 +9 ==========================================
Hits 2430 2430 - Misses 1877 1886 +9 
Partials 141 141 

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

@mbrtmbrt left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Great stuff, left only minor comments, thanks!

Comment threadcmd/gmailctl/cmd/apply_cmd.go Outdated
Comment threadcmd/gmailctl/cmd/apply_cmd.go Outdated
Comment threadcmd/gmailctl/cmd/diff_cmd.go Outdated
Comment threadcmd/gmailctl/cmd/diff_cmd.go Outdated
Comment threadcmd/gmailctl/cmd/edit_cmd.go Outdated
Comment threadcmd/gmailctl/cmd/edit_cmd.go Outdated
This adds a `--context` option to the `diff` subcommand and a `--diff-context` option to the `apply` and `edit` commands. The option allows the number of lines of diff context to be customized, which is helpful for verifying the correctness of changes to more complex filters.
@kpengboy
kpengboy requested a review from mbrtJanuary 19, 2025 04:27
@mbrt
mbrt merged commit 6b9e153 into mbrt:masterJan 19, 2025
@mbrtmbrt added the kind/feature New feature or request label Jan 19, 2025
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/featureNew feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@kpengboy@mbrt