-
Notifications
You must be signed in to change notification settings - Fork 49
Fix parsing of non-extended file headers and lines starting with -- #55
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
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
@@ -0,0 +1,5 @@ | ||||||||||||||||||||||||
@@ -1,4 +1,3 @@ | ||||||||||||||||||||||||
select 1; | ||||||||||||||||||||||||
--- this is my query | ||||||||||||||||||||||||
select 2; | ||||||||||||||||||||||||
select 3; | ||||||||||||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is that a case that works? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You mean, with the fix here or in general? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. With the logic above that checks the next hunk line for line
---line
+++line
line I guess. Would this be parseable? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If I use this diff, it crashes: diff --git a/foobar.sql b/foobar.sql
index 9537d7b..f73c856 100644
--- a/foobar.sql
+++ b/foobar.sql
@@ -1,5 +1,5 @@
select 1;
--- this is my query
+++ this is my query
select 2;
select 3;
--- this is the last line
+++ this is the last line I'll try to see if I can make that work. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @keegancsmith @eseliger what do you think of this? #56 It adds a custom type, |
Uh oh!
There was an error while loading. Please reload this page.