-
Notifications
You must be signed in to change notification settings - Fork 15.2k
[emacs][clang-format] Add elisp API for clang-format on git diffs #112792
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
goldsteinn
merged 17 commits into
llvm:main
from
goldsteinn:goldsteinn/emacs-clang-format-git
Feb 4, 2025
Merged
Changes from all commits
Commits
Show all changes
17 commits
Select commit
Hold shift + click to select a range
802764e
[emacs][clang-format] Add elisp API for clang-format on git diffs
goldsteinn 2c8395d
Address V2 Comments
goldsteinn fc05d68
Rename 'git' -> 'vc' and 'diffs' -> 'diff'
goldsteinn 36aa80b
Complete sentences/byte-compile/refactor vc check
goldsteinn fcf504f
use diff-no-select
goldsteinn b42785d
Revert "use diff-no-select"
goldsteinn 95db21c
comment why no diff-no-select
goldsteinn 98d5894
Use 'diff-command' from diff.el
goldsteinn 1e65249
git-vc-program/ignore errors
goldsteinn 7cdfa4e
Ignore errors deleting both
goldsteinn 6d49dcf
Nits/Diff command that doesn't req regex
goldsteinn 7742bd1
Use macro for cleaning files
goldsteinn 9ae26d4
Compat Dif
goldsteinn e547d0e
Optimize diff search
goldsteinn b277560
Use re-search-format
goldsteinn 8c8c551
Update regex/getting matches
goldsteinn 92247c1
Address Comments
goldsteinn File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
*picky* - personal preference, but I find it odd that the function returns command line arguments for clang-format.
It can return a list of cons-pairs of instead
(list (cons int int) ...)instead, then the clang-format function can convert them to the arguments used by clang-format.(the patch I attached did this), it's not a big change, I'd expect a formatting function that can operate on multiple ranges to take int-pairs instead of a list of strings.