-
Notifications
You must be signed in to change notification settings - Fork 22
Remove check that prevents adding newlines before the last line #50
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
Remove check that prevents adding newlines before the last line #50
Conversation
|
Replaces #49, the NuGet package updates broke 2015 compatibility. |
| firstLine = false; | ||
| } | ||
|
|
||
| while (hasElements) |
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.
Ran into this issue again, and I think the above is a cleaner fix.
| sortedLines = sortedLines.Where(sortedLine => !string.IsNullOrWhiteSpace(sortedLine.RawLine)); | ||
| } | ||
|
|
||
| // Finally, update the actual lines |
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.
Instead of doing what we were doing before to insert original non-include lines, this merges those in ahead of time. That way, there's less weird broken logic trying to do it on the fly :)
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.
Ohhh I really like the approach with the select that sneaks in the lines from the other enumerator. Never occurred to me to be honest
| <PackageManifest Version="2.0.0" xmlns="http://schemas.microsoft.com/developer/vsx-schema/2011" xmlns:d="http://schemas.microsoft.com/developer/vsx-schema-design/2011"> | ||
| <Metadata> | ||
| <Identity Id="IncludeToolbox.Andreas Reich.075c2e2b-7b71-45ba-b2e6-c1dadc81cfac" Version="2.2.0.1" Language="en-US" Publisher="Andreas Reich" /> | ||
| <Identity Id="IncludeToolbox.Andreas Reich.075c2e2b-7b71-45ba-b2e6-c1dadc81cfac" Version="2.2.1" Language="en-US" Publisher="Andreas Reich" /> |
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.
Bug fix versioned
| "; |
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.
You'll see a lot of empty lines in the "expected output", because every test except one removes duplicates, and there are a lot of duplicates.
de88fd1 added a check to prevent adding a newline before the last line in
a batch. Since we're prepending, however, a newline is desirable if the
last line is the only one in its group.
Fixes #48